Twelve Data: Features, API, Pricing, API Key and Alternatives

Financial applications, trading platforms and investment tools depend on accurate market information to display prices, monitor assets and analyse financial trends. Collecting this information from multiple exchanges and data providers can be difficult, especially when an application needs real-time updates and historical records.
Twelve Data is a financial market data platform that helps developers, traders, analysts and businesses access financial information through a unified API. It provides data covering stocks, forex, cryptocurrencies, ETFs, mutual funds and other financial instruments.
Instead of integrating separate data sources for different asset classes, developers can use Twelve Data's REST API and WebSocket services to retrieve and stream market information through a consistent interface.
But what does Twelve Data actually offer? Is its API free? How can you get an API key, and which pricing plan is suitable for your project?
This guide explains its features, supported markets, API integration, pricing, advantages, limitations and alternatives to help you understand whether the platform meets your requirements.
What Is Twelve Data Used For?
Twelve Data is used to retrieve, process and integrate financial market data into websites, applications, trading systems and analytical tools.
Its unified API allows developers to request different types of financial information without building separate integrations for every market.
The platform supports several common use cases:
- Stock market applications: Display current stock prices, historical performance and company information.
- Forex platforms: Retrieve currency exchange rates and historical forex data.
- Cryptocurrency applications: Access cryptocurrency prices and exchange-related market information.
- Trading dashboards: Monitor multiple financial instruments through API requests and real-time data streams.
- Financial research: Analyse historical prices, company fundamentals and technical indicators.
- Investment platforms: Integrate market information into portfolio tracking and financial analysis tools.
Twelve Data also offers spreadsheet integrations, developer libraries and tools for businesses that need structured financial information.
According to its official platform information, its data coverage includes more than 500,000 financial instruments across different asset classes.
Twelve Data API: How Does It Work?
The Twelve Data API connects applications with financial market data through standardised requests and responses.
Developers send requests to the platform's API endpoints, specify the financial instrument they want to retrieve, and authenticate using an API key.
The platform processes the request and returns the available information in a structured format, such as JSON or CSV.
Twelve Data provides two primary methods of accessing market information.
1. REST API
The REST API allows applications to request financial information whenever needed.
For example, a developer building a stock market dashboard can request the latest price of Apple (AAPL), retrieve historical prices or access company information.
Common REST API use cases include:
- Retrieving stock prices and quotes.
- Accessing historical market data.
- Getting forex exchange rates.
- Retrieving cryptocurrency prices.
- Searching financial symbols.
- Accessing company fundamentals.
- Calculating technical indicators.
The REST API supports JSON and CSV responses, making it suitable for different development environments.
2. WebSocket API
The WebSocket API is designed for applications that require continuous market updates.
Unlike traditional REST requests, which retrieve information when an application sends a request, WebSocket connections allow servers to push updates to connected clients.
This is useful for:
- Live stock price dashboards.
- Real-time cryptocurrency monitoring.
- Trading applications.
- Market tracking systems.
- Financial analytics platforms.
Developers can subscribe to supported symbols and receive updates through a persistent connection.
Both API methods serve different purposes. REST is suitable for requesting information when needed, while WebSocket is useful for continuously receiving market updates. Access and subscription limits depend on the selected plan.
What Financial Data Does Twelve Data Provide?
One of the main features of Twelve Data is its coverage of multiple financial markets through a unified platform.
Rather than focusing exclusively on stocks or currency exchange rates, it provides several categories of financial information.
Stock Market Data
The Twelve Data stock API provides access to stock prices, historical records, company information and other equity-related data.
Developers can use this information to create stock tracking applications, financial dashboards and investment research tools.
Common stock-related data includes:
- Real-time and historical stock prices.
- Intraday price information.
- Daily and end-of-day data.
- Company profiles.
- Dividends and stock splits.
- Earnings information.
- Stock market reference data.
Coverage and availability depend on the exchange, instrument and subscription plan.
Forex Market Data
The Twelve Data forex API provides currency exchange information for developers building currency converters, forex dashboards and financial applications.
Its forex-related services include:
- Currency exchange rates.
- Historical forex data.
- Currency pair information.
- Intraday price records.
- Exchange rate conversion.
This allows developers to retrieve currency information through the same general API structure used for other financial markets.
Cryptocurrency Data
Twelve Data also provides cryptocurrency market information through its cryptocurrency API.
This service is useful for applications that need to monitor digital asset prices and analyse historical market performance.
Its cryptocurrency coverage includes:
- Cryptocurrency prices.
- Exchange-related market data.
- Historical price information.
- Cryptocurrency reference data.
- Technical analysis indicators.
The platform lists more than 1,900 cryptocurrency pairs in its current product information.
ETFs and Mutual Funds Data
Twelve Data also supports exchange-traded funds (ETFs) and mutual funds.
This information can help developers build investment research platforms, portfolio analysis tools and applications that track fund performance.
Depending on the plan and dataset, available information includes fund prices, historical records, holdings, profiles and performance-related metrics.
Commodities and Other Financial Data
The platform also provides access to commodities, including metals and energy-related instruments.
Additional datasets cover financial fundamentals, corporate actions, technical indicators, analyst estimates and other research-related information.
The exact datasets available depend on the subscription and applicable market-data licensing.
How to Get a Twelve Data API Key
To start using Twelve Data, you need an account and an API key. The key authenticates your requests and allows the platform to associate API usage with your subscription.
Follow these steps to get your Twelve Data API key.
Step 1: Visit the official website
Open Twelve Data's official website and navigate to the account registration section.
Step 2: Create an account
Register using the available sign-up options and complete the required account information.
Step 3: Access your dashboard
After signing in, open your account dashboard, where you can access your API credentials and usage information.
Step 4: Copy your API key
Locate your API key and copy it. Keep the key private because it is used to authenticate requests.
Step 5: Make your first API request
You can test the connection using a simple price request.
For example:
curl "https://api.twelvedata.com/price?symbol=AAPL&apikey=YOUR_API_KEY"
Replace YOUR_API_KEY with your own API key.
If the request is valid and your plan permits access to the requested data, the API returns the available price information.
The official documentation also recommends authentication through an HTTP header:
Authorization: apikey YOUR_API_KEY
This avoids placing your API key directly in the request URL.
Important: Do not publish your API key in publicly accessible JavaScript, GitHub repositories or client-side application code. Store sensitive credentials securely on your server.
Twelve Data API Documentation
The Twelve Data API documentation provides technical instructions for developers who want to integrate financial market information into their applications.
It explains how to authenticate requests, use API endpoints, select parameters and interpret responses.
The documentation includes several important sections:
| Documentation section | What it covers |
|---|---|
| Getting started | Account setup and first API request |
| Authentication | API keys and request authentication |
| Market data | Prices, quotes and historical records |
| Reference data | Symbols and exchange information |
| Fundamentals | Company financial information |
| Technical indicators | Financial analysis calculations |
| WebSocket | Continuous market data streaming |
| SDKs and libraries | Development integrations |
| Error codes | Understanding API errors |
| API usage | Monitoring credits and request limits |
Developers can also find official libraries and integration guidance for Python, Node.js, Go, Java and R.
For the latest endpoints, supported parameters and implementation examples, visit the official Twelve Data API documentation.
Twelve Data Python Integration
Python is commonly used for financial analysis, data processing, algorithmic research and application development.
Twelve Data supports Python integration, allowing developers to retrieve market information and process it using Python libraries.
A basic example using Python's requests library is shown below.
import requestsAPI_KEY = "YOUR_API_KEY"url = "https://api.twelvedata.com/time_series"params = { "symbol": "AAPL", "interval": "1day", "outputsize": 5, "apikey": API_KEY}response = requests.get(url, params=params)data = response.json()print(data)
This example requests five daily historical data points for Apple stock.
The returned information can then be processed using libraries such as Pandas for analysis or Matplotlib for visualisation.
For production applications, developers should also handle API errors, request limits, missing values and authentication securely.
Is Twelve Data Free?
Yes. Twelve Data offers a free Basic plan for testing, learning and personal projects.
However, free access comes with usage restrictions, and not every dataset or feature is available under the Basic subscription.
The Basic plan currently includes:
- $0 monthly subscription cost.
- 8 API credits per minute.
- 800 API credits per day.
- 8 trial WebSocket credits.
- Real-time US equities and ETFs.
- Real-time forex data.
- Real-time cryptocurrency data.
The free plan is useful for developers who want to test API functionality before committing to a paid subscription.
However, it is important to distinguish between personal use and commercial use. Twelve Data's Basic plan is not licensed for commercial use. Businesses displaying data to customers or making it part of a public product may need a commercial licence.
Twelve Data Pricing: Which Plan Should You Choose?
Twelve Data offers different subscription levels depending on API usage, market coverage and the type of data required.
Its individual pricing page lists Basic, Grow, Pro and Ultra plans.
The following table shows representative starting prices from the individual pricing options:
| Plan | Starting monthly price | Best suited for |
|---|---|---|
| Basic | Free | Testing and small personal projects |
| Grow | $29/month | Hobby projects and moderate API usage |
| Pro | $99/month | Advanced integrations |
| Ultra | $329/month | Higher-volume personal use |
Prices vary according to API credits, WebSocket credits and billing frequency. Annual billing can reduce the monthly equivalent.
The platform also provides additional datasets and exchange-specific add-ons, which may involve separate charges.
Commercial users: Do not assume that an individual subscription is suitable for a public-facing financial application. Twelve Data provides separate business pricing for commercial data usage.
For current prices, licence conditions and plan comparisons, check the official Twelve Data pricing page.
Advantages and Limitations of Twelve Data
Before choosing a financial market data provider, it is important to understand both its strengths and limitations.
Advantages
1. Multiple asset classes in one API
Twelve Data provides stocks, forex, cryptocurrency, ETFs, mutual funds and commodities through a unified platform.
2. REST and WebSocket support
Developers can retrieve information through standard API requests or receive continuous updates through WebSocket connections.
3. Developer-friendly documentation
The platform offers technical documentation, SDKs and integration resources to simplify development.
4. Historical and real-time information
Depending on the plan and instrument, users can access historical records and real-time market information.
5. Free Basic plan
Developers can experiment with the platform without paying a monthly subscription.
Limitations
1. API usage restrictions
The free plan has daily and per-minute limits, so applications with high data requirements may need a paid subscription.
2. Different market coverage across plans
Not every exchange, instrument or dataset is available at every subscription level.
3. Commercial licensing requirements
Developers building public-facing products need to check the applicable commercial data licence.
4. WebSocket credits
Continuous market streaming consumes WebSocket credits, which must be considered when estimating the cost of a real-time application.
5. Pricing complexity
The number of API credits, market coverage, data entitlements and add-ons can make it necessary to compare plans carefully before subscribing.
Twelve Data vs Alpha Vantage
Twelve Data and Alpha Vantage are two financial data providers that developers may consider when building market-related applications.
Both provide API access to financial information, but their product offerings, data coverage, pricing structures and usage limits differ.
| Comparison factor | Twelve Data | Alpha Vantage |
|---|---|---|
| Main offering | Financial market data APIs | Financial market data APIs |
| Stock data | Yes | Yes |
| Forex data | Yes | Yes |
| Cryptocurrency data | Yes | Yes |
| Historical data | Yes | Yes |
| WebSocket streaming | Yes | Check current product and plan terms |
| Technical indicators | Yes | Yes |
| Developer documentation | Yes | Yes |
| Pricing structure | Credit-based subscription tiers | Free and paid options |
The best provider depends on your application.
Twelve Data may be worth evaluating when you need unified market coverage, WebSocket streaming and multiple asset classes through one integration.
Alpha Vantage is another option to investigate when comparing API access, technical indicators and available data plans.
Before choosing either service, compare current API limits, exchange coverage, data delays, licensing requirements and total subscription costs.
Twelve Data Alternatives
Twelve Data is not the only provider offering financial market data APIs.
Depending on your development requirements, you may also consider other services.
1. Alpha Vantage
Alpha Vantage provides APIs for stock market data, forex, cryptocurrency and technical indicators.
It is an option for developers who need financial data for analytical tools and market-related applications.
2. Finnhub
Finnhub provides financial information covering stocks, forex, cryptocurrency, company fundamentals and market news.
It also offers real-time data capabilities and APIs for financial applications.
3. Polygon.io
Polygon.io provides market data APIs for stocks, options, forex and cryptocurrency.
It is particularly relevant for developers building market monitoring, trading and financial analytics applications.
4. iTick
iTick provides financial market data APIs through REST, WebSocket and FIX interfaces.
Its documentation covers stocks, forex, futures, funds, indices and cryptocurrency. It also provides separate API endpoints for different markets and environments.
Developers comparing financial market data providers can explore iTick's financial market data API endpoints to understand its available interfaces and supported asset classes.
iTick may be worth evaluating when a project requires different market-data interfaces or institutional-level connectivity. Check its current access requirements, data coverage and licensing before selecting it.
Frequently Asked Questions About Twelve Data
What is Twelve Data?
Twelve Data is a financial market data provider that offers APIs for stocks, forex, cryptocurrency, ETFs, mutual funds and other financial instruments. Developers use its services to integrate financial information into applications and analytical systems.
Is Twelve Data API free?
Yes. Twelve Data offers a free Basic plan with 800 API credits per day and 8 API credits per minute. However, the free plan has restrictions on data access and commercial usage.
How do I get a Twelve Data API key?
Create an account on the official Twelve Data website, sign in to your dashboard and locate your API credentials. Copy your key and use it to authenticate API requests.
What is the Twelve Data API used for?
The API is used to retrieve stock prices, forex rates, cryptocurrency information, historical records, company fundamentals and technical indicators for financial applications.
Does Twelve Data support Python?
Yes. Developers can integrate Twelve Data with Python using its supported libraries or standard HTTP requests. Retrieved data can then be analysed using Python tools such as Pandas.
Does Twelve Data provide real-time stock data?
Yes. Twelve Data provides real-time market information for supported instruments and markets. However, availability depends on the subscription plan, exchange and data licensing conditions.
What is the Twelve Data API pricing?
Twelve Data offers a free Basic plan and paid Grow, Pro and Ultra subscriptions. Pricing depends on API credits, WebSocket usage, data access and billing frequency.
Is Twelve Data suitable for commercial applications?
It can be suitable for commercial applications, but businesses must select an appropriate commercial licence. Individual plans are intended for personal or internal use and do not automatically provide public redistribution rights.
Does Twelve Data offer a WebSocket API?
Yes. Its WebSocket API allows developers to subscribe to supported financial instruments and receive market updates through persistent connections.
What are the best Twelve Data alternatives?
Alpha Vantage, Finnhub and Polygon.io are alternatives worth comparing. iTick is another option for developers looking for REST, WebSocket or FIX-based financial market data interfaces.
Final Thoughts
Twelve Data is a financial market data platform designed to simplify access to different asset classes through a unified API.
Its combination of REST requests, WebSocket streaming, historical information, developer documentation and spreadsheet integrations makes it useful for developers, researchers and financial technology businesses.
However, choosing the right plan requires more than comparing monthly subscription prices. API limits, market coverage, data freshness and commercial licensing can all affect whether the platform is suitable for a particular project.
Before integrating Twelve Data into your application, test the required endpoints, review the documentation and confirm that your chosen subscription supports your intended use.