This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to get Gene ID from NCBI accession for non model species ?

Hi all,

I have a non model species so R packages where you specify your genome/annotation don't work and I also tried https://david.ncifcrf.gov/conversion.jsp but got no result.

I have an accession (ex: XP_025269744.1) and want to retrieve the GeneID (ex: 112639560).

Example with this link:

https://www.ncbi.nlm.nih.gov/protein/XP_025269744.1

Any solutions please ?

gene id ncbi accession

1 answer

Using NCBI Entrezdirect:

$ esearch -db protein -query "XP_025269744" | elink -target gene | esummary | xtract -pattern DocumentSummary -element Id
112639560

$ esearch -db protein -query "XP_025269744" | elink -target gene | efetch 

1. LOC112639560
juvenile hormone acid O-methyltransferase-like [Camponotus floridanus (Florida carpenter ant)]
Other Designations: juvenile hormone acid O-methyltransferase-like
Chromosome: Un
ID: 112639560

Thanks for your answer @genomax.

I got an issue with the -db option. Which database are u using ?

Depending on your query you will need to use an appropriate database. nuccore is option for nucleotide database, if you have nucleotide accession numbers.

Log in to answer this question.