Skip to main content

PostgreSQL TimescaleDB Extensions

You can add extensions to databases PostgreSQL TimescaleDB. Extensions allow you to add functionality to a database without changing the source code of the DBMS itself.

For a list of extensions available in Managed Databases, see the Extension description table.

Some extensions require connecting a public library.

Some extensions depend on others—dependent extensions will not work without the main extension. For a list of dependent and main extensions, see the Dependent extensions table.

You can add an extension in the dashboard, through the Managed Databases API, or through Terraform.

Connect public libraries for extensions

Some extensions require connecting public libraries. To connect a library, when creating a cluster or changing settings in an existing cluster, specify its name in the shared_preload_libraries setting.

In cluster PostgreSQL TimescaleDB the following libraries are supported:

  • pg_cron — for the pg_cron extension;

  • pg_prewarm — for the pg_prewarm extension.

Add extension

Extensions are connected separately to each database. If you connect a dependent extension and the main extension is not yet connected, the main extension will be connected automatically first, followed by the dependent one.

  1. In the Dashboard, on the top menu, click Products and select Managed Databases.
  2. Open the Active tab.
  3. Open the cluster page → Databases tab → database card.
  4. In the Extensions block, click Add extension.
  5. Select an extension. For a list of available extensions and their descriptions, see the Extension description table.
  6. Click Add.

Delete extension

A dependent extension can be deleted separately. To delete the main extension, first delete the dependent one. For a list of dependent and main extensions, see the Dependent extensions table.

  1. In the Dashboard, on the top menu, click Products and select Managed Databases.
  2. Open the Active tab.
  3. Open the cluster page → Databases tab → database card.
  4. In the Extensions block, in the extension row, click .

Extension description

address_standardizerUsed for structuring postal addresses transmitted as a string
address_standardizer_data_usUsed for structuring US and Canadian postal addresses for the address_standardizer extension
autoinc

Contains the autoinc() function. This function returns the next value for a sequence stored in an integer field. Unlike built-in sequence-managing types, autoinc():

  • blocks attempts to insert a value from a query into the field;
  • allows changing the value in the field when updating a record
bloomAdds access to database indexes based on Bloom filters, which require significantly less memory than hash tables but allow for false positives
btree_ginContains examples of the GIN (Generalized Inverted Index) operator class, used for reverse searching
btree_gistContains GiST (Generalized Search Tree) operator classes. Unlike B-tree indexes, GiST supports the <> (not equal) and < - > (distance) operators, although it does not guarantee the uniqueness of returned values
citextContains the citext data type, used for case-insensitive string operations
clickhouse_fdw

Allows a PostgreSQL TimescaleDB cluster to connect directly to ClickHouse databases using Foreign Data Wrapper.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users.

Extension available for PostgreSQL TimescaleDB version 15 or higher

cubeContains the cube data type, used for representing multidimensional cubes
dblinkSupports connecting from the current session to other PostgreSQL databases
dict_intContains an example of an additional dictionary template for full-text search, which can help prevent the list of unique words from growing and increase search speed
dict_xsynContains an example of an Extended Synonym Dictionary template for full-text search: when searching for a word, all its synonyms will be found
fuzzystrmatchContains functions used for determining string similarity and difference
h3-pg

Provides an API to H3 — an open system for indexing geographic objects in a grid of hexagonal zones (tiles). It allows you to divide territory into identical tiles for geospatial data analysis, such as building heatmaps and analyzing traffic or mobility. It can be used together with PostGIS for extended geospatial data analysis.

Extension available for PostgreSQL TimescaleDB version 15 or higher

hstoreContains the hstore type, which allows storing key/value pairs in a single table field and working with them efficiently
intarrayContains functions and operators for working with integer arrays that contain no NULL values
ip4rSupports indexing of IPv4 and IPv6 addresses to improve query performance
isnContains data types for international product numbering standards EAN13, UPC, ISBN, ISMN, and ISSN. Number validation and formatting are performed according to a specified list of prefixes
jsonb_plperl

Adds support for json and jsonb data types in the PL/Perl procedural language. It allows using JSON data directly when writing Perl functions and triggers

jsqueryAllows using the JsQuery language for working with jsonb data types. JsQuery allows for efficient searching in nested objects and contains additional comparison operators with index support
loContains the lo type and the lo_manage() function, which are used for managing binary large objects (BLOBs) in accordance with JDBC and ODBC driver requirements (the default PostgreSQL behavior does not meet these specifications)
ltreeContains the ltree data type for representing data labels stored in a tree-like hierarchical structure
moddatetimeContains the moddatetime() function, which allows tracking the last modification time of a table row
mysql_fdw

Allows a PostgreSQL TimescaleDB cluster to connect directly to MySQL databases using Foreign Data Wrapper.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users.

Extension available for PostgreSQL TimescaleDB version 15 or higher

oracle_fdw

Allows a PostgreSQL TimescaleDB cluster to connect directly to Oracle databases using Foreign Data Wrapper.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pg_buffercache

Allows monitoring the state of the shared buffer cache in real time.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pg_cron

Allows for the scheduling of SQL queries within a database.

Requires connecting a public library pg_cron.

The extension can only be connected to one database per cluster. To connect the extension to a different database, first delete it from the current one.

Connecting this extension will cause the cluster to restart.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pg_prewarm

Allows loading relation data into the operating system cache or the PostgreSQL buffer cache.

Requires connecting a public library pg_prewarm.

Connecting this extension will cause the cluster to restart.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pg_repack

Allows rebuilding tables and indexes without blocking, in order to reduce their size and fragmentation.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users

pg_stat_statements

Adds capabilities for tracking planning and collecting execution statistics for all SQL queries run in the cluster.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users

pg_trgm

Contains tools for quickly finding similar strings based on trigram matching.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pg_uuidv7

Contains functions for generating UUID version 7.

Extension available for PostgreSQL TimescaleDB version 15 or higher

pgcryptoProvides a set of cryptographic functions for data protection. For more information about data encryption using the pgcrypto extension and examples of use, see the Data encryption guide
pgrowlocksContains the pgrowlocks() function, which returns information about row-level locks in a specified table
pgstattuple

Provides detailed statistics on disk space usage and allows analyzing index fragmentation, the number of dead tuples, and free space. The extension is useful for performance diagnostics, index optimization, planning VACUUM operations, and using the pg_repack extension

pgTAPProvides a set of tools for testing database schemas and SQL functions
plpgsql

Allows using the PL/pgSQL procedural language for creating functions, procedures, and triggers. This extension is enabled by default and is automatically available in all databases created in the cluster. It does not need to be connected separately via the dashboard

plv8Allows using JavaScript for writing stored procedures and triggers
postgis

Allows storing and processing geographic information system (GIS) objects in PostgreSQL databases.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users

postgis_rasterAllows working with raster images and conducting analysis for geographic information systems (GIS) in databases
postgres_fdw

Allows a PostgreSQL TimescaleDB cluster to connect directly to data stored on external PostgreSQL servers (other clusters) using Foreign Data Wrapper.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users

prefixAllows using prefixes and masks to optimize queries
rumAdds an access method for working with RUM indexes
segContains the seg data type for representing line segments or floating-point intervals
tablefuncContains a set of functions that return tables (row sets)
tcn

Provides a trigger function for creating notifications about changes in tables to which the trigger is attached.

Extension available for PostgreSQL TimescaleDB version 15 or higher

tsm_system_rows

Provides a sampling method by number of rows (SYSTEM_ROWS), which can be used in the TABLESAMPLE clause of the SELECT command.

Extension available for PostgreSQL TimescaleDB version 15 or higher

tsm_system_time

Provides a sampling method by execution time (SYSTEM_TIME), which can be used in the TABLESAMPLE clause of the SELECT command.

Extension available for PostgreSQL TimescaleDB version 15 or higher

unaccentContains a dictionary for searching text without regard to diacritical marks
uuid-osspContains functions for generating UUIDs according to standard algorithms
vectorAllows working with vector data—storing, indexing, and executing queries
xml2Allows using XPath queries and the XSLT language

Dependent extensions

earthdistanceContains a module for calculating distances between points on the Earth's surface. Works only in conjunction with the main cube extension
pg_stat_kcache

Adds the ability to collect statistics on read and write operations performed at the file system level. Works only in conjunction with the main pg_stat_statements extension.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users

pgroutingContains functions for geospatial routing in PostGIS databases. Works only in conjunction with the main postgis extension
postgis_tiger_geocoderContains functions for geocoding based on data in TIGER format. Works only in conjunction with the main postgis extension
postgis_topology

Contains data types and functions for the postgis extension for managing topological objects. Works only in conjunction with the main postgis extension.

The dbaas_admin role is required to use this extension. This role is automatically assigned to the database owner and cannot be assigned to other users