Telephone
United States
+1 (800) 815 - 9959
10:00 AM - 5:00 PM (EST/EDT)
Monday - Friday
Need help?
Telephone
United States
+1 (800) 815 - 9959
10:00 AM - 5:00 PM (EST/EDT)
Monday - Friday
Your API key lets you send requests through the Semrush API.
To get your key:
Before making your first request, check your API unit balance to ensure it's sufficient for your use case.
All API methods include request examples, providing a great starting point for your requests.
Domain Overview request example
https://api.semrush.com/?key=API_KEY&type=domain_ranks&export_columns=Db,Dn,Rk,Or,Ot,Oc,Ad,At,Ac,Sh,Sv&domain=apple.com&database=us
https://api.semrush.com/
.?
to add request parameters.key=API_KEY
. Replace API_KEY
with your API key.&
to separate parameters. You'll need to add &
after each parameter.type=domain_ranks
domain=apple.com
database=us
export_columns=Db,Dn,Rk,Or,Ot,Oc,Ad,At,Ac,Sh,Sv
Note that the URL format may vary depending on the product and report. Refer to the .Trends API docs for the .Trends API request example.
Certain types of reports within Semrush API support the display_limit
parameter. Use it to limit the number of lines returned in a response to save on API units.
For example, adding &display_limit=10
will limit your request to the top 10 results.
When making API requests, parameter values containing special characters must be converted to URL-encoded strings. To simplify the process, you can use a URL encoder.
The characters typically used in Semrush API calls (for example, as Filters) are:
Character | Encoded |
---|---|
# | %23 |
& | %26 |
* | %2A |
+ | %2B |
- | %2D |
: | %3A |
| | %7C |
% | %25 |
/ | %2F |
This step is optional. Be aware that test calls to the Semrush API will consume your API units.
Before integrating the Semrush API into your workflow, test your API request using Postman or cURL to ensure it returns the expected data.
To automate data retrieval from the Semrush API, create a script in your preferred programming language that handles API calls, data processing, storage, and integration with BI tools or other platforms.
Key steps:
The Semrush API key is an identification key assigned to you after subscribing to Semrush. You'll find it in Subscription info > API units.
Since it’s sensitive information, you can’t do it by yourself. If you suspect that your API key may be compromised, contact Semrush Tech Support. They will update the API key for you.
The Semrush API can address many business needs, from optimizing SEO/PPC ROI to enhancing your market strategy.
To pick the right API type and methods for you, check out the most common Semrush API use cases.
Semrush API generally charges units in one of two ways:
Note that all requests to the Listing Management API and Map Rank Tracker API don’t spend API units.
For details on how many units each request can consume, check the prices on the method pages. To learn how to calculate costs and optimize your API requests, refer to Limit consumption.
You can check your remaining API unit balance using a free API call or through the Semrush UI:
Semrush provides elaborate API documentation that walks you through finding the right methods for your use case and creating calls. You can browse through the API methods available and check out the Get started guide.
If you have any questions, feel free to contact Semrush Tech Support.
If you need help with troubleshooting, get in touch with Semrush Tech Support.
The data you can access depends on the tool you’re requesting it from. To learn what countries are available in the Semrush API, refer to Stats. Check the information for the corresponding Semrush tools and reports.
There are rate and usage limits in place, depending on the API. To review the rate and usage limits, refer to API usage restrictions.
If major changes are made, Semrush will let you know about them with reasonable advance notice. For minor changes, review the API documentation. For specific inquiries, contact Semrush Tech Support or your account representative.