Share via Nextstrain Groups


This how-to guide assumes familiarity with the Nextstrain Groups feature and the Nextstrain dataset files produced by running a pathogen workflow. We recommend reading about those first if you’re not familiar with them.

Log in with the Nextstrain CLI

Before you can upload data to your Nextstrain Group, you need to log into with the Nextstrain CLI’s nextstrain login command so it knows how to access your group’s data.

nextstrain login

Confirm that you have access to your group by running nextstrain whoami.

nextstrain whoami

You should see your group name in the output.

You can also try listing your group’s datasets and narratives with nextstrain remote list. Replace ${GROUPNAME} below with your group name.

nextstrain remote list${GROUPNAME}

This will likely return nothing for now since groups start without any datasets or narratives. However, the lack of an error is useful to see.

Upload a Nextstrain dataset


Do not upload any files containing personally identifiable information (PII). This restriction applies for public and private groups.

Upload one or more Nextstrain datasets for your group using the nextstrain remote upload command. An example using a dataset produced by our ncov workflow. The pattern of your dataset and sidecar filenames and desired display URL to upload may be different.

nextstrain remote upload \${GROUPNAME}/ncov/${YOUR_BUILD_NAME} \
    auspice/ncov_${YOUR_BUILD_NAME}.json \
    auspice/ncov_${YOUR_BUILD_NAME}_tip-frequencies.json \

After the upload completes, it’ll appear in the group listing when you run:

nextstrain remote list${GROUPNAME}

You can also navigate to your groups page on the web to see the dataset listed there.

If you have multiple datasets to upload, you can do so with one command if their filenames match the URLs you want.

nextstrain remote upload${GROUPNAME} auspice/*.json

Remove a dataset

Use the nextstrain remote delete command to remove a dataset or narrative you’ve uploaded.

nextstrain remote delete${GROUPNAME}/ncov/${YOUR_BUILD_NAME}


Below is an example of what the steps above look like for a user trs and group test:

$ nextstrain login
Logging into…

Username: trs

Credentials saved to /home/tom/.nextstrain/secrets.

Logged into as trs.
Log out with `nextstrain logout`.

$ nextstrain whoami
username: trs
email: tsibley@…
  - test/editors

$ nextstrain remote list

$ nextstrain remote upload \ \
      auspice/ncov_example.json \
      auspice/ncov_example_tip-frequencies.json \
Uploading auspice/ncov_example.json as
Uploading auspice/ncov_example_root-sequence.json as (root-sequence)
Uploading auspice/ncov_example_tip-frequencies.json as (tip-frequencies)

$ nextstrain remote list

$ nextstrain remote delete

You’ll of course have to login as yourself, and be sure to replace test with your group’s name when you try it!

Learn more

Learn more about the above commands and parameters in the following reference material: