Skip to content

Thoughts on Saleforce

A community dedicated to making Salesforce, it's products, and partners better...

Click to register with for a FREE 30-DAY TRIAL!


Login Form

Lost Password?
No account yet? Register

URL Structure

table.url-info {margin-top:1em;margin-left:1em;width:90%}
table.url-info th {text-align:left;background-color:whitesmoke;;padding:0.25em;}
table.url-info td {padding:0.25em;}
.longurl {font-size:0.8em;font-family:Courier New,Courier,Monospace;}
.footnotes {font-size:0.8em;}
.sidebar {float:right;margin-left:1em;font-size:0.9em;width:25%;border:thin solid red;padding:1em;background-color:whitesmoke;}
img.browserurl {border:thin solid; margin-left:1em;margin-bottom:1em;}
li {font-size:1.1em;}

URL for adding an Account to with return to the Home Page

Recently I decided I wanted to create soom "quick launch" bookmarklets for I wanted buttons on my browser toolbar that would take me to specific Mods in and execute the exact action I wanted without having to first visit a page with such a link, or worse having to use that infernal little drop down for creating new records/objects. For example, I really wanted a button for creating a new Account that was always available.

Of course creating a quick launch button requires understanding’s URL structure because in their infinte wisdom has decided that Professional and Team customers are second class and don’t need access to the API because we are just not sophisticated enough to need it. (Sorry there if my sarcasm there is just a bit too obvious.)

Anyway, though I didn’t do an exhaustive search, I googled and couldn’t find anything that explained it so I attempted to grok it on my own. Based on my research which I was obviously only able to do with my own account and thus might not fully apply to others, It appears their URLs work something like this assuming you are logged into

Code Module URL to Module Home Page
001 Accounts https://<s>
003 Contacts https://<s>
006 Opportunities https://<s>
015 Documents https://<s>
500 Cases https://<s>
501 Solutions https://<s>
800 Contracts https://<s>
00O Reports https://<s>
00Q Leads https://<s>
01Z Dashboards https://<s>
a00 Custom Tabs1 https://<s>
a01 Products https://<s>

 1 Of course this is just for the first custom tab. Not sure about what happens we you create more.

For <s> I have always found it to be "na1" for (I assume) "North American server #1" (although I tried "sa1" and "eu1" and they both gave me a "Could not find domain" result in my browser so maybe that theory isn’t so good.) I even tried to set up a secondary DNS server to pull down the subdomains for, but they evidently have them configured to block Zone transfers (go figure!). Here’s my CMD window/NSLookup transcript:

C:Program FilesSupport Tools>nslookupDefault Server:  xxxxAddress:

> salesforce.comServer:  xxxxAddress:

Non-authoritative answer:Name:    salesforce.comAddress:

> set type=ns> salesforce.comServer:  xxxxAddress:

Non-authoritative  nameserver =  nameserver =  nameserver =  nameserver =  nameserver =  nameserver =    internet address =      internet address =

Moving on, I researched URLs for the following actions:

URL to Excute Acction
View All Objects


View Object’s Home


View Object


Add Object


Edit Object


Clone Object


Add Related Task


In the above table:

  • The term "Object" refers to a instance/record in a Module, i.e. an Account, a Lead, a Contact, etc.
  • retURL will often start with "%2F" when viewed in your browser. %2F is just the hex-encoded equivalent of "/" that the browser performs automatically on such characters when found in URL parameters.
  • <s> always seemed to be "na4" for these URLs, but your mileage may vary.
  • <m> refers to the three position alphanumeric from the first table (i.e. "003" for Contacts and "01Z" for Dashboards.)
  • <o> refers to the internal ID that maintains for every unique object in its system. If you ever use the Excel Connector for mass data updates you’ll get to directly play with them (Professional Editions and above only;  Team Edition customers need not apply.).
  • <r> refers to the previous domain-relative URL (i.e. starting with a "/" instead of "") to which should return after the user completes the request action. If retURL is omitted, returns to "/home/home.jsp".
  • who_id refers to the Object to which the task should be associated, prefix with it’s Mod code.

If it’s more than a few days since Oct. 1, 2006 you might want to also check out this link for updated information:

Salesforce’s URL structure

There are a lot of other URLs in, but they start breaking down in consistency and use different conventions for similar concepts as if different groups within implemented them and they didn’t have the foresight to coordinate on conventions. However, I think I’ve documented the most important URLs and with the above information you can probably grok any others on your own.  Besides. I wasn’t planning on writing a complete manual on URLs when I sat down to write this post. :)

BTW, one of my ongoing campaigns has for a long time been to see more web developers and designed consider URL design to be an important component of web application design. As such, I recently launched a website called with a mission to encourage more people to recognize the value of good URL design. On the aspect of URL design, I would give a grade of B+ which is much better than I would give most websites.

At among other things I plan to (get people to) document URL Structure for the various websites and installable web applications, especially if not documented by their respective vendor. That said, I’m going to copy this information about’s URL Structure over to wiki and potentially augment it over time.

If you do end up figuring out any of the other URLs, please just on over to the’s URL Structure section on the wiki for  and document the layout for the benefit of future seekers of the same information. Also go ahead and post a comment  here indicating which URL you documented and a another link to the wiki page where your updates can be found.