Which is faster: PostgreSQL vs MongoDB on large JSON datasets?
For data load, Postgre outperforms MongoDB.
MongoDB is almost always faster when returning query counts.
PostgreSQL is almost always faster for queries using indexes.

Check out this website  and this one too for more info. They have very detailed explanations.