Skip to main content

Read the latest Real Python tutorials

Project description


Sometimes we need to download a sequencing project from ENA, fortunately ENA offers in its platform a link to the fastq file that we need. However, we can spend a lot of time downloading files manually if the amount of files is large.

I have developed a small project in python to be able to do this work in an automated and parallel way to increase the performance.


pip install getENA Alternatively, from GitHub pip install git+


Let's say I'm interested in Clostridium perfringens sequencing projects, we have to search ENA for public sequencing projects at From there, we choose the codes we need, for example:

PRJNA350702 PRJNA285473 PRJNA508810

We have 2 options to download the FASTQ files, (1) add the project codes to the command line separated by spaces as an argument, or (2) make a file containing a list of all the project codes that need.

For the first option (recommended for few projects for example < 5) we run the following -p PRJNA350702 PRJNA285473 PRJNA508810

For the second option (recommended for many projects e.g. >= 5) we run the following -pfile ena.list.txt

Where ena.list.txt is the file containing a list of all the project codes.

If you want, you can increase the performance by increasing the number of reads that are downloaded in parallel (-t option). However, be careful, because ENA aborts the connection if it detects that you have many connections at the same time with its FTP. Empirically I have observed that 12 parallel connections work properly without ENA cancelling the download.

As a crazy example of many parallel connections of the above commands would be the following: -t 64 -p PRJNA350702 PRJNA285473 PRJNA508810

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for getENA, version 1.0.2
Filename, size File type Python version Upload date Hashes
Filename, size getENA-1.0.2-py3-none-any.whl (17.2 kB) File type Wheel Python version py3 Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page