Use Grafana with InfluxDB
This page documents an earlier version of InfluxDB OSS. InfluxDB 3 Core is the latest stable version.
Use Grafana or Grafana Cloud to visualize data from your instance.
Identify your InfluxDB version
If you are unsure which InfluxDB product you are using, use our interactive version detector to help identify it:
Required
- The instructions in this guide require Grafana Cloud or Grafana v10.3+. For information about using InfluxDB with other versions of Grafana, see the Grafana documentation.
- To use Flux, use InfluxDB 1.8.1+ and enable Flux in your InfluxDB configuration file.
Install Grafana
If running Grafana locally, enable the
newInfluxDSConfigPageDesign
feature flag to use the latest InfluxDB data source plugin.For more information, see Configure feature toggles in the Grafana documentation.
Visit your Grafana Cloud user interface (UI) or, if running Grafana locally, start Grafana and visit http://localhost:3000 in your browser.
Using Grafana Cloud with a local InfluxDB instance
If you need to keep your database local, consider running Grafana locally instead of using Grafana Cloud, as this avoids the need to expose your database to the internet.
To use InfluxDB running on your private network with Grafana Cloud, you must configure a private data source for Grafana Cloud.
SQL is only supported in InfluxDB 3. For more information, see how to get started with InfluxDB 3 Core.
Create an InfluxDB data source
- In your Grafana interface, click Connections in the left sidebar.
- Click Data sources.
- Click Add new connection.
- Search for and select InfluxDB. The InfluxDB data source configuration page displays.
- In the Settings tab, enter a Name for your data source.
Configure URL and authentication
In the URL and authentication section, configure the following:
- URL: Your server URL–for example,
https://localhost:8086
- Product: From the dropdown, select InfluxDB OSS 1.x
- Query Language: Select InfluxQL or Flux
- (Optional) Advanced HTTP Settings, Auth, and TLS/SSL Settings as needed for your environment
Configure database settings
The fields in this section change based on your query language selection in URL and authentication.
Configure Grafana to use InfluxQL
When you select InfluxQL as the query language, configure the following:
- Database: Your database name
- User: Your InfluxDB username (if authentication is enabled); leave blank if authentication is disabled.
- Password: Your InfluxDB password (if authentication is enabled); leave blank if authentication is disabled.

Click Save & Test. Grafana attempts to connect to InfluxDB and returns the result of the test.
Configure Grafana to use Flux
When you select Flux as the query language, configure the following:
Ensure Flux is enabled in your InfluxDB configuration file.
Configure the database settings:
- Organization: Provide an arbitrary value (InfluxDB 1.x does not use organizations)
- Default Bucket: Provide a default database and retention policy
- Token: If InfluxDB authentication is enabled provide your InfluxDB username and password

Click Save & Test. Grafana attempts to connect to InfluxDB and returns the result of the test.
Query and visualize data
With your InfluxDB connection configured, use Grafana to query and visualize time series data.
Query inspection in Grafana
To learn about query management and inspection in Grafana, see the Grafana Explore documentation.
Build visualizations with Grafana
For a comprehensive walk-through of creating visualizations with Grafana, see the Grafana documentation.
Was this page helpful?
Thank you for your feedback!
Support and feedback
Thank you for being part of our community! We welcome and encourage your feedback and bug reports for InfluxDB and this documentation. To find support, use the following resources:
Customers with an annual or support contract can contact InfluxData Support.