Quick start
This guide will get your first QuestDB instance running.
As the goal is to, well, start quickly, we'll presume defaults.
Once running, we'll provide guides for inserting data, configuration and production hosting.
QuestDB already running? Jump ahead! Select a first-party client or ingest method.
Install QuestDB
Choose from the following options:
Docker
To use Docker, one must have Docker. You can find installation guides for your platform on the official documentation.
Once Docker is installed, pull and run QuestDB:
docker run -p 9000:9000 -p 8812:8812 -p 9003:9003 questdb/questdb:9.2.3
This exposes the Web Console (9000), PostgreSQL wire (8812), and health endpoint (9003).
For deeper instructions, see the Docker deployment guide.
Homebrew
To install QuestDB via Homebrew, run the following command:
brew install questdb
On macOS, the location of the root directory of QuestDB and server configuration files depend on the chip:
-
Apple Silicon (M1/M2/M*) chip:
/opt/homebrew/var/questdb -
Intel chip:
/usr/local/var/questdb
Binaries
Download and run QuestDB via binaries.
Select your platform of choice:
- Linux
- Windows
- Any (no JVM)
questdb-9.2.3-rt-linux-x86-64.tar.gz
Next, unpack it:
tar -xvf questdb-9.2.3-rt-linux-x86-64.tar.gz
$HOME/.questdb
questdb-9.2.3-rt-windows-x86-64.tar.gz
The default root directory becomes:
C:\Windows\System32\qdbroot
Download the binary:
questdb-9.2.3-no-jre-bin.tar.gz
This package does not embed Java.
Use this if there is no package for your platform, such as ARM Linux.
Requires local Java 17.
To check your installed version:
java -version
If you do not have Java, install one of the following:
- AdoptOpenJDK
- Amazon Corretto
- OpenJDK
- Oracle Java
Other Java distributions might work but are not tested regularly. For example, it is known that Azul Zing 17 is incompatible.
For environment variable, point JAVA_HOME to your Java 17 installation folder.
Run QuestDB
- Linux/No JVM
- macOS (Homebrew)
- Windows
./questdb.sh start
To stop: ./questdb.sh stop | To check status: ./questdb.sh status
All options
./questdb.sh [start|stop|status] [-d dir] [-f] [-n] [-t tag]
| Option | Description |
|---|---|
-d | Expects a dir directory value which is a folder that will be used as QuestDB's root directory. For more information and the default values, see the default root section below. |
-t | Expects a tag string value which will be as a tag for the service. This option allows users to run several QuestDB services and manage them separately. If this option is omitted, the default tag will be questdb. |
-f | Force re-deploying the Web Console. Without this option, the Web Console is cached and deployed only when missing. |
-n | Do not respond to the HUP signal. This keeps QuestDB alive after you close the terminal window where you started it. |
questdb start
To stop: questdb stop | To check status: questdb status
All options
questdb [start|stop|status] [-d dir] [-f] [-n] [-t tag]
| Option | Description |
|---|---|
-d | Expects a dir directory value which is a folder that will be used as QuestDB's root directory. For more information and the default values, see the default root section below. |
-t | Expects a tag string value which will be as a tag for the service. This option allows users to run several QuestDB services and manage them separately. If this option is omitted, the default tag will be questdb. |
-f | Force re-deploying the Web Console. Without this option, the Web Console is cached and deployed only when missing. |
-n | Do not respond to the HUP signal. This keeps QuestDB alive after you close the terminal window where you started it. |
questdb.exe start
To stop: questdb.exe stop | To check status: questdb.exe status
All options
questdb.exe [start|stop|status|install|remove] \
[-d dir] [-f] [-j JAVA_HOME] [-t tag]
| Option | Description |
|---|---|
install | Installs the Windows QuestDB service. The service will start automatically at startup. |
remove | Removes the Windows QuestDB service. It will no longer start at startup. |
-d | Expects a dir directory value which is a folder that will be used as QuestDB's root directory. For more information and the default values, see the default root section below. |
-t | Expects a tag string value which will be as a tag for the service. This option allows users to run several QuestDB services and manage them separately. If this option is omitted, the default tag will be questdb. |
-f | Force re-deploying the Web Console. Without this option, the Web Console is cached and deployed only when missing. |
-j | Windows only! This option allows to specify a path to JAVA_HOME. |
Verify installation
Open http://localhost:9000 in your browser.
You should see the QuestDB Web Console.
Try running your first query in the SQL editor:
CREATE TABLE test (ts TIMESTAMP, val DOUBLE) TIMESTAMP(ts);
INSERT INTO test VALUES (now(), 42.5);
SELECT * FROM test;
It works? You're ready to bring your data.
Default ports:
| Port | Service |
|---|---|
9000 | REST API and Web Console |
9009 | InfluxDB Line Protocol (ILP) - Legacy TCP, use HTTP instead |
8812 | PostgreSQL Wire Protocol |
9003 | Health endpoint |
Bring your data
Now... Time to really blast-off. 🚀
Next up: Bring your data - the life blood of any database.
Choose from one of our premium ingest-only language clients:
Python
Python is a programming language that lets you work quickly and integrate systems more effectively.
Want more options? See the ingestion overview.
Create new data
No data yet and still want to trial QuestDB?
There are several quick options:
- QuestDB demo instance: Hosted, fully loaded and ready to go. Quickly explore the Web Console and SQL syntax.
- Create my first data set guide: create
tables, use
rnd_functions and make your own data. - Sample dataset repos: IoT, e-commerce, finance or git logs? Check them out!
- Quick start repos: Code-based quick starts that cover ingestion, querying and data visualization using common programming languages and use cases. Also, a cat in a tracksuit.
- Time series streaming analytics template: A handy template for near real-time analytics using open source technologies.
Learn QuestDB
For operators or developers looking for next steps to run an efficient instance, see:
- Capacity planning for recommended configurations for operating QuestDB in production
- Configuration to see all of the available options in
your
server.conffile - Schema design essentials for tips and tricks
- Visualize with Grafana to create useful
dashboards and visualizations from your data
- Looking for inspiration? Checkout our real-time crypto dashboard.