From Source (Windows)

Note: TimescaleDB requires PostgreSQL 12.0 or 13.2, or later


  • A standard PostgreSQL 13 64-bit installation
  • Visual Studio 2017 (with CMake and Git components) or Visual Studio 2015/2016 (with CMake version 3.11+ and Git components)
  • Make sure all relevant binaries are in your PATH: pg_config and cmake

Build and install with local PostgreSQL


It is highly recommended that you checkout the latest tagged commit to build from (see the repo's Releases page for that)

Clone the repository from GitHub:

git clone
cd timescaledb
git checkout <release_tag>  # e.g., git checkout 2.2.1

If you are using Visual Studio 2017 with the CMake and Git components, you should be able to open the folder in Visual Studio, which will take care of the rest.

If you are using an earlier version of Visual Studio:


This install step has to be made as admin.
# Bootstrap the build system

# To build the extension from command line
cmake --build ./build --config Release

# To install
cmake --build ./build --config Release --target install

# Alternatively, open build/timescaledb.sln in Visual Studio and build,
# then open & build build/INSTALL.vcxproj


You will need to edit your postgresql.conf file to include the TimescaleDB library, and then restart PostgreSQL. First, locate your postgresql.conf file:

psql -d postgres -c "SHOW config_file;"

Then modify postgresql.conf to add the required library. Note that the shared_preload_libraries line is commented out by default. Make sure to uncomment it when adding our library.

shared_preload_libraries = 'timescaledb'


If you have other libraries you are preloading, they should be comma separated.

Then, restart the PostgreSQL instance.

Updating from TimescaleDB 1.x to 2.0

Once the latest TimescaleDB 2.0 are installed, you can update the EXTENSION in your database as discussed in Updating Timescale to 2.0.


Our standard binary releases are licensed under the Timescale License, which allows to use all our capabilities. To build a version of this software that contains source code that is only licensed under Apache License 2.0, pass -DAPACHE_ONLY=1 to bootstrap.

Found an issue on this page?

Report an issue!


Related Content