- Home
- Genomes
- Genome Browser
- Tools
- Mirrors
- Downloads
- My Data
- Projects
- Help
- About Us
The easiest way to save and share tracks from the URL is by logging in to your Genome Browser account and creating a saved session. Saved sessions are a versatile way to share data that may include native annotations, Custom Tracks, Track Hubs, and Assembly Hubs. In these examples, text in brackets "<" and ">" indicate places where the user supplies information. Note that the brackets are not needed for the URL, including the brackets will result in a 'Could not find session' error.
You will be able to share Genome Browser sessions with the following link format:
http://genome.ucsc.edu/s/<userName>/<sessionName>
For instructions on creating a saved session, go to the session user guide. If you want to specify track settings in a URL directly, please read the section on setting track visibility via URL for a complete description.
Or if you prefer the older style, which allows you to link to different tools, you may use the following parameters:
hgS_otherUserName=<userName>
hgS_otherUserSessionName=<sessionName>
hgS_doOtherUser=submit
Here is an example:
http://genome.ucsc.edu/cgi-bin/hgTracks?hgS_doOtherUser=submit&hgS_otherUserName=<userName>&hgS_otherUserSessionName=<sessionName>
This longer format has the flexibility of replacing "hgTracks" with different tool names to share saved settings on the Table Browser (hgTables), Variant Annotation Integrator (hgVai), or Data Integrator (hgIntegrator). This will preserve your option selections and can be useful to share. The following format will bring the recipient to a user's custom Table Browser selections:
http://genome.ucsc.edu/cgi-bin/hgTables?hgS_doOtherUser=submit&hgS_otherUserName=<userName>&hgS_otherUserSessionName=<sessionName>
Both session link formats have the advantage of being able to add URL parameters to the end. The shorter link format requires a question mark before any URL parameters, with ampersand characters separating different parameters like so:
http://genome.ucsc.edu/s/view/clinicalzoom?textSize=18
Both formats require an ampersand between each additional parameter, seen in the longer format like so:
Another option for sessions is to download the file and host it in an external location and load it with
hgS_doLoadUrl=submit
and
hgS_loadUrlName=<URL>
allowing you to externally maintain your session,
or update it as you wish. Here is an example:
You can link to a specific genome assembly and position in the Genome Browser using a URL with
the db=
and position=
parameters.
http://genome.ucsc.edu/cgi-bin/hgTracks?db=<assembly>&position=<position>
Where:
db
- designates a specific genome assembly. For example, db=hg19
refers to the Feb. 2009 human genome release. For a list of db parameter values that
correspond to UCSC assemblies, see the list of UCSC
releases.position
- can be any search term for the genome specified, including
a position range or a gene identifier. This often takes the form of
position=chr1:35000-40000
.The following link is an example of a URL that declares assembly and position:
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg19&position=chr1:35000-40000
You can link directly to the default position of an assembly by passing the
position=default
parameter. This can be helpful in cases where
a track exists on multiple assemblies, and you want to build links to each of them. If no
position variable is passed, the Genome Browser assumes the default position for the
default assembly (hg38).
Here is an example which opens the uniprot track at the default position for sacCer3:
http://genome.ucsc.edu/cgi-bin/hgTrackUi?db=sacCer3&g=uniprot&position=default
To link to a specific HGVS identifier, you can construct a link with the HGVS identifier
in the position field instead of coordinates. The default padding is 5bp on either side,
but you can always zoom in or out with hgt.out1=submit
or hgt.in1=submit
.
The numbers 1 through 4 zoom in or out corresponding to the buttons above the track window.
The following lists the zoom levels of each number, applicable to zooming in or out:
hgt.out1=submit
zooms out 1.5xhgt.out2=submit
zooms out 3xhgt.out3=submit
zooms out 10xhgt.out4=submit
zooms out 100xThe following link is an example which leads to the variant NM_00257:c.1208G>T and zooms out 3x:
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg19&position=NM_000257:c.1208G>T&hgt.out2=submit
You can control the visibility of tracks from the URL with the following parameters, each linked by the "&" sign:
guidelines=on/off
- activate or deactivate the blue guidelines -
example link to switch off blue guidelineshgFind.matches=<listOfNames>
- highlight features given their names -
example link to highlight two transcripts of the ABO genehgt.reset=1
- show only the default tracks -
example linkhgt.toggleRevCmplDisp=1
- show the reverse-complement -
example link to show the reverse-complement of the ABO genehgt.labelWidth=<number>
- set the size of the left-side label area -
example link to increase the label area to 50 charactershideTracks=1
- hide all tracks -
example link to show no tracks at allhideTracks=1&<trackName>=full|dense|pack|hide
- hide all tracks and show
other tracks -
example link to show only the Chromosome Bands track and nothing elsehighlight=<db>.<chrom>:<chromStart>-<chromEnd>#<color>|...
-
highlight one or more regions in a given color on the image. Note that the arguments have to be
URL-encoded for Internet browsers, so ":" becomes "%3A", "#"
becomes "%23" and "|" becomes "%7"C. -
example link to highlight two parts of the ABO locus in red and blue.ignoreCookie=1
- do not load the user's existing settings saved
in the internet browser's UCSC Genome Browser cookie. This means that the link will show the
Genome Browser default
settings such as track selections, custom tracks, and track hubs. Any changes
you make in this new session will, however, affect the user's settings. E.g.,
if you add a track in this new window, and come back to the genome browser
later, the track will still be there. This setting is useful if a website
wants to link to the Genome Browser, starting with a "clean slate" but
believes the user will come back to the Genome Browser expecting the
changes to still be there. ruler=hide
- hide the ruler at the top of the browser image -
example link to hide the ruleroligoMatch=pack&hgt.oligoMatch=<dnaSeq>
- switch on the Short Match track and
highlight a matching sequence -
example link to highlight the TATAWAR motif in the ABO locuspix=<number>
- set the width of the image in pixels -
example link to create a 300-pixel wide imagetextSize=<number>
- sets browser text size to either 6, 8, 10, 12, 14, 18, 24,
or 34. Default is a textSize of 12. -
example link to increase the text font size to 18 pixels<trackName>=full|pack|dense|hide
- sets specified track or subtrack to a
chosen visibility: full, pack, dense, or hide track -
example link to show the
Chromosome Bands track set to "pack" and added to your view as saved in your cart.
Please note that for this feature to work with
custom tracks you must use the unique name and identifier number
ct_name_####
assigned by our system. You can determine the name for a custom track
using the url,
https://genome.ucsc.edu/cgi-bin/cartDump.
<trackName>_imgOrd=<number>
- vertically orders the tracks on the image
based on the numbers provided. You need to specify an order for every visible track when using this
parameter -
example link to show two show knownGene track being listed second with gtex first<trackName>.heightPer=<number>
- sets a bigWig track's height to a
particular number of pixels (between 20-100) -
example link to set umap bigWig track height to 100 pixels
<trackName>_hideKids=1
- hides a specific super track's individual tracks -
example link to hide the Encode Regulation super track<trackName>_sel=1
- selects specific subtrack to be 'checked', allowing
display - example
link to select the checkbox for UCSC RefSeq subtrack in the refSeq composite track, allowing
display alongside default tracks
For example, you can use the following command to hide every track (hideTracks=1), set the genome database to hg38 (db=hg38), set the mappability track to full visibility (mappability=full), and set the umap track height to 100 pixels (umap24Quantitative.heightPer=100). Each of these parameters can be used individually or in combination.
Composite tracks have additional URL parameters that encode options to hide, select, and display subtracks.
<trackName>_hideKids=1
- hides a specific composite track's subtracks<trackName>_sel=1
- selects specific subtrack to be 'checked', allowing
displayFor example, the following URL hides all tracks (hideTracks=1), hides a specific composite track's default subtracks (refSeqComposite_hideKids=1), turns on one specific subtrack (ncbiRefSeqCurated=full), and checks a box to display that subtrack (ncbiRefSeqCurated_sel=1).
https://genome.ucsc.edu/cgi-bin/hgTracks?db=hg38&hideTracks=1&refSeqComposite_hideKids=1&ncbiRefSeqCurated=full&ncbiRefSeqCurated_sel=1
If you have a custom track on a web-accessible server, you can use the location of the file
to load it directly as part of a URL.
You can combine the URL visibility settings with the hgct_customText=
parameter using
a track line you would otherwise put in the custom track
input box. The following example shows the hgct_customText
parameter accepting
a bigBed file URL as a custom track:
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg38&position=chr21:34821279-34888690&hgct_customText=https://genome.ucsc.edu/goldenPath/help/examples/bigBedExample.bb
If you want to add more information to the Custom Track, you can do so using the
hgct_customText
parameter. Since this is a URL, you must use "%20" to encode
for spaces and "%0A" for a new line character. For example, the following example shows Custom
Track input pasted in the custom track input box and the
equivalent input in the URL:
browser position chr21:33038946-33039092 track type=bam bigDataUrl=https://genome.ucsc.edu/goldenPath/help/examples/bamExample.bam name=Example description=ExampleBAM
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg38&hgct_customText=browser%20position%20chr21:33038946-33039092%0Atrack%20type=bam%20bigDataUrl=https://genome.ucsc.edu/goldenPath/help/examples/bamExample.bam%20name=Example%20description=ExampleBAM
More information on custom track parameters can be found in the Custom Track user guide.
Similar to custom tracks, track hubs can be loaded into the URL using the
hubUrl=
parameter. This parameter takes input similar to the
track hub input box. The following example
links to the hg19 genome database and an example track Hub:
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg19&hubUrl=https://genome.ucsc.edu/goldenPath/help/examples/hubDirectory/hub.txt
Track hubs' track visibility can also be changed from the URL parameters. The following link specifies the genome database (db=hg19), loads a track hub (hubUrl=http.../hub.txt), hides all tracks (hideTracks=1), hides the subtrack kids of a particular track (gtexRnaSignalMaleYoung_hideKids=1), sets a specific subtrack to be displayed (gtexRnaSignalSRR1311243=full), and ignores user settings (ignoreCookie=1).
https://genome.ucsc.edu/cgi-bin/hgTracks?db=hg19&hubUrl=http://hgdownload.soe.ucsc.edu/hubs/gtex/hub.txt&hideTracks=1>exRnaSignalMaleYoung_hideKids=1>exRnaSignalMaleYoung=full>exRnaSignalSRR1311243=full&ignoreCookie=1
To link to an assembly hub and display data on a non-natively supported genome, the same
parameters apply. To specify the intended genome assembly, instead of using db=
,
you must use genome=araTha1
, where araTha1 is the assembly name set by
your genomes.txt file in the line genome araTha1
.
https://genome.ucsc.edu/cgi-bin/hgTracks?genome=araTha1&hubUrl=http://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubAssembly/plantAraTha1/hub.txt
To see the files behind that assembly hub, please visit the hub's directory. For more information on assembly hubs in general, please see the assembly hub wiki, the track hub user guide, or the quick start guide to assembly hubs.
hubClear=
to remove hubs at the same location
Another feature one can use in place of hubUrl=
is
hubClear=
, which will load a hub while simultaneously disconnecting
or clearing, hubs located at the same location. For example, adding
hubClear=http://university.edu/lab/folder/hub10.txt
would connect the
referenced hub10.txt while simultaneously disconnecting any hubs that might be
displayed from the same http://university.edu/lab/folder/
directory
(for example, hub1.txt, hub2.txt, etc.). This feature can be useful for dynamically
generated hubs that might collect in the browser otherwise.
Alongside hubUrl
and hubClear
there are other parameters
you can add to either if you wished, for instance, to attach an assembly hub and
display the Gateway page, while also sharing your contact email.
hgHubConnect.remakeTrackHub=on
acts to connect when pointed to /hgHubConnecthgHub_do_firstDb=1
uses the first database in genomes.txthgHub_do_redirect=on
redirects the attached hub to the Gateway page
By pointing the URL to /cgi-bin/hgHubConnect
the hub would be connected to
and then redirect to the Gateway page to display the page in genomes.txt
defined
by the htmlPath ../newOrg.html
line. Here is an example:
http://genome.ucsc.edu/cgi-bin/hgHubConnect?hgHub_do_redirect=on&hgHubConnect.remakeTrackHub=on&hgHub_do_firstDb=1&hubUrl=http://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubAssembly/plantAraTha1/hub.txt
genome=
for assembly hubs
There is also another way to connect an assembly hub using the genome=
to arrive at
the Gateway page if you know the genome in genomes.txt
that you wish to display.
For instance, the below link skips the redirection step, where your
hub.txt
contact email gets displayed, by pointing to the
/cgi-bin/hgGateway
page:
http://genome.ucsc.edu/cgi-bin/hgGateway?genome=araTha1&hubUrl=http://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubAssembly/plantAraTha1/hub.txt
It is possible to attach a track hub to an assembly hub via the URL using a combination of the
hubUrl=
and genome=
URL parameters. For example, using the following
assembly hub and track hub:
Arabidopsis thaliana assembly hub https://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubPlants/cshl2013/hub.txt
ReMap2020 Reg. Atlas track hub https://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubRemap/remap.txt
The combination of the two hubs, along with genome=araTha1
, allows for the creation of
the following URL that can load both hubs on the Genome Browser.
https://genome.ucsc.edu/cgi-bin/hgTracks?genome=araTha1&hubUrl=https://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubPlants/cshl2013/hub.txt&hubUrl=https://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubRemap/remap.txt
When creating a track hub for a GenArk assembly, there is no need to do any attaching of the
assembly hub itself via the hubUrl=
URL parameter. GenArk hubs will automatically
attach themselves if the track hub mentions the GCA_ or GCF_ name identifier of the assembly hub.
Simply load the track hub on the Genome Browser, and the assembly hub will automatically appear. For
example, the following example track hub will load an additional track for the pig (GCA_002844635.1)
GenArk assembly.
To create a link to the track hub that references a GenArk assembly, the
genome=GCA_002844635.1
and hubUrl=
URL parameters can be used like in the
following example:
https://genome.ucsc.edu/cgi-bin/hgTracks?genome=GCA_002844635.1&hubUrl=https://genome.ucsc.edu/goldenPath/help/examples/hubExamples/hubGenArkExample/genArkTrackHub/hub.txt
You can also read a blog post, Sharing Data with Sessions and URLs, about how to build URLs to track hubs on assembly hubs or see further examples of GenArk hubs loaded with custom data.
To jump directly to a gene's position on the Genome Browser, set the position parameter in the
URL to a gene symbol (e.g., TP53, MTOR, KRAS) and add the parameter
singleSearch=knownCanonical
. For example, the following link will open the
Genome Browser for the hg19 human assembly at the position of TP53 on the knownCanonical dataset
http://genome.ucsc.edu/cgi-bin/hgTracks?db=hg19&singleSearch=knownCanonical&position=TP53
You can also link directly to gene description pages from the URL. Instead of a position search,
gene descriptions use the hgg_gene=
URL parameter. The following URL connecting
to 'hgGene' will open up the Genome Browser description page containing protein function,
expression profile, and links to additional information for the gene TP53.
http://genome.ucsc.edu/cgi-bin/hgGene?db=hg19&hgg_gene=TP53
The hgsid is a temporary user ID that stores setting and custom track information in the URL. Including it in any shared URLs is a privacy concern, and it should be removed when constructing any links to the Genome Browser. Most significantly, it will change after you share it. Anyone using it will see that last thing you did, not what you thought you were sharing. Creating Saved Sessions is the recommended way to share Genome Browser information.
For more information, please see our section on URL parameters for custom tracks. If you cannot find what you are looking for, please contact our active mailing list by emailing genome@soe.ucsc.edu. All messages sent to that address are publicly archived. If your question includes sensitive data, you may send it instead to genome-www@soe. ucsc.edu
Visit our YouTube channel.
Visit our YouTube channel.
Visit our YouTube channel.