DBMS > MongoDB vs. PostgreSQL vs. TiDB
System Properties Comparison MongoDB vs. PostgreSQL vs. TiDB
Please select another system to include it in the comparison.
|Editorial information provided by DB-Engines
|MongoDB Xexclude from comparison
|PostgreSQL Xexclude from comparison
|TiDB Xexclude from comparison
|One of the most popular document stores available both as a fully managed cloud service and for deployment on self-managed infrastructure
|Widely used open source RDBMS Developed as objectoriented DBMS (Postgres), gradually enhanced with 'standards' like SQL
|TiDB is an open source distributed SQL database that supports Hybrid Transactional/Analytical Processing (HTAP) workloads. It is MySQL compatible and features horizontal scalability, strong consistency, and high availability.
|Primary database model
|Relational DBMS with object oriented extensions, e.g.: user defined types/functions and inheritance. Handling of key/value pairs with hstore module.
|Secondary database models
Search engine integrated Lucene index, currently in MongoDB Atlas only.
Time Series DBMS Time Series Collections introduced in Release 5.0
Vector DBMS currently available in the MongoDB Atlas cloud service only
Graph DBMS with Apache Age
Vector DBMS with pgvector extension
|PostgreSQL Global Development Group www.postgresql.org/developer
|1989 1989: Postgres, 1996: PostgreSQL
|6.0.7, June 2023
|16.2, February 2024
|7.6.0, January 2024
|License Commercial or Open Source
|Open Source MongoDB Inc.'s Server Side Public License v1. Prior versions were published under GNU AGPL v3.0. Commercial licenses are also available.
|Open Source BSD
|Open Source Apache 2.0
|Cloud-based only Only available as a cloud service
|no MongoDB available as DBaaS (MongoDB Atlas)
|DBaaS offerings (sponsored links) Database as a Service
Providers of DBaaS offerings, please contact us to be listed.
|MongoDB Atlas: Global multi-cloud database with unmatched data distribution and mobility across AWS, Azure, and Google Cloud, built-in automation for resource and workload optimization, and so much more.
|Aiven for PostgreSQL: Fully managed PostgreSQL for developers with 70+ extensions and flexible orchestration tools.
|TiDB Cloud: Fully-managed TiDB Service. Bring everything great about TiDB to the cloud.
|Server operating systems
|schema-free Although schema-free, documents of the same collection often follow the same structure. Optionally impose all or part of a schema by defining a JSON schema.
|Typing predefined data types such as float or date
|yes string, integer, double, decimal, boolean, date, object_id, geospatial
|XML support Some form of processing data in XML format, e.g. support for XML data structures, and/or support for XPath, XQuery or XSLT.
|yes specific XML-type available, but no XML query functionality.
|SQL Support of SQL
|Read-only SQL queries via the MongoDB Atlas SQL Interface
|yes standard with numerous extensions
|APIs and other access methods
proprietary protocol using JSON
native C library
streaming API for large objects
|Supported programming languages
|Actionscript unofficial driver
Clojure unofficial driver
ColdFusion unofficial driver
D unofficial driver
Dart unofficial driver
Delphi unofficial driver
Groovy unofficial driver
Lisp unofficial driver
Lua unofficial driver
MatLab unofficial driver
PowerShell unofficial driver
Prolog unofficial driver
R unofficial driver
Smalltalk unofficial driver
|Server-side scripts Stored procedures
|user defined functions realized in proprietary language PL/pgSQL or with common languages like Perl, Python, Tcl etc.
|yes in MongoDB Atlas only
|Partitioning methods Methods for storing different data on different nodes
|Sharding Partitioned by hashed, ranged, or zoned sharding keys. Live resharding allows users to change their shard keys as an online operation with zero downtime.
|partitioning by range, list and (since PostgreSQL 11) by hash
|horizontal partitioning (by key range)
|Replication methods Methods for redundantly storing data on multiple nodes
|Multi-Source deployments with MongoDB Atlas Global Clusters
|Source-replica replication other methods possible by using 3rd party extensions
|Using Raft consensus algorithm to ensure data replication with strong consistency among multiple replicas.
|MapReduce Offers an API for user-defined Map/Reduce methods
|yes with TiSpark Connector
|Consistency concepts Methods to ensure consistency in a distributed system
|Eventual Consistency can be individually decided for each read operation
Immediate Consistency default behaviour
|Foreign keys Referential integrity
|no typically not used, however similar functionality with DBRef possible
|yes full support since version 6.6
|Transaction concepts Support to ensure data integrity after non-atomic manipulations of data
|Multi-document ACID Transactions with snapshot isolation
|Concurrency Support for concurrent manipulation of data
|Durability Support for making data persistent
|yes optional, enabled by default
|In-memory capabilities Is there an option to define some or all structures to be held in-memory only.
|yes In-memory storage engine introduced with MongoDB version 3.2
|User concepts Access control
|Access rights for users and roles
|fine grained access rights according to SQL-standard
|Fine grained access rights according to SQL-standard
|More information provided by the system vendor
|MongoDB provides an integrated suite of cloud database and data services to accelerate...
|TiDB is an advanced open-source, distributed SQL database for modern application...
|Built around the flexible document data model and unified API, MongoDB is a developer...
|- HORIZONTAL SCALING : TiDB grants total transparency into your data workloads without...
|Typical application scenarios
|AI-enriched intelligent apps (Continental, Telefonica, Iron Mountain) Internet of...
|TiDB is ideal for transactional applications that require extreme scalability and...
|ADP, Adobe, Amadeus, AstraZeneca, Auto Trader, Barclays, BBVA, Bosch, Cisco, CERN,...
|Block, Pinterest, Catalyst, Bolt, Flipkart, Capcom, Shopee (E-commerce), JD Cloud...
|Hundreds of millions downloads, over 150,000+ Atlas clusters provisioned every month...
|34K+ GitHub stars 5K+ members in TiDB Community Slack 1K+ community contributors...
|Licensing and pricing models
|MongoDB database server: Server-Side Public License (SSPL) . Commercial licenses...
|TiDB Community : Free open source software (Apache 2.0) TiDB Self-Hosted : Enterprise...
We invite representatives of system vendors to contact us for updating and extending the system information,
|Related products and services
|Navicat for MongoDB gives you a highly effective GUI interface for MongoDB database management, administration and development.
CData: Connect to Big Data & NoSQL through standard Drivers.
Studio 3T: The world's favorite IDE for working with MongoDB
|Fujitsu Enterprise Postgres: An Enterprise Grade PostgreSQL with the flexibility of a hybrid cloud solution combined with industry leading security, availability and performance.
Instaclustr: Fully Hosted & Managed PostgreSQL
Navicat Monitor is a safe, simple and agentless remote server monitoring tool for PostgreSQL and many other database management systems.
pgDash: In-Depth PostgreSQL Monitoring.
SharePlex is the reliable and affordable data replication solution for PostgreSQL migrations, high availability and more.
Navicat for PostgreSQL is an easy-to-use graphical tool for PostgreSQL database development.
Redgate webinars: A series of key topics for new PostgreSQL users.
Aiven for PostgreSQL: Fully managed PostgreSQL for developers with 70+ extensions and flexible orchestration tools.
Timescale: Calling all PostgreSQL users – the 2023 State of PostgreSQL survey is now open! Share your favorite extensions, preferred frameworks, community experiences, and more. Take the survey today!
Datasentinel: Platform for Monitoring and Analyzing the performance problems of your PostgreSQL Clusters
We invite representatives of vendors of related products to contact us for presenting information about their offerings here.
|DB-Engines blog posts
Snowflake is the DBMS of the Year 2021
PostgreSQL is the DBMS of the Year 2023 Snowflake is the DBMS of the Year 2022, defending the title from last year
Snowflake is the DBMS of the Year 2022, defending the title from last year
|Recent citations in the news
Broadcom, Target, MongoDB And Jobs Data: Investing Action Plan
LPL Financial LLC Acquires 5,329 Shares of MongoDB, Inc. (NASDAQ:MDB)
MongoDB (MDB) Exceeds Market Returns: Some Facts to Consider
Wells Fargo, MongoDB Look Toward the Future
provided by Google News
Best of Makers: PostgreSQL Takes a New Turn
AWS announces Amazon Aurora PostgreSQL integration with Amazon Bedrock for Generative AI
Blog Theme - Details
MongoDB vs PostgreSQL: A Comparison of Databases 
Oracle Introduces PostgreSQL Running Native on OCI
provided by Google News
TiDB 7.5 Sets New Standard for Stability at Scale
Announcing TiDB 7.4: The Best Database Alternative for MySQL 8.0
PingCAP Included as an Honorable Mention in the 2023 Gartner® Magic Quadrant™ for Cloud Database Management ...
provided by Google News
Share this page