Visualising WKT geometry string in QGIS

Current answer

Try "QuickWKT" Plugin.

Old answer

Try "QuickWKT" plugin. You have to allow experimental plugins to be able to install it.

enter image description here


Indeed there is! Look here for how to achieve it with the Add Delimited Text Layer plugin.

Essentially you create a CSV file (although you should use a delimiter other than comma), where one column is the WKT representation of your geometry. Then when you select that file in the plugin, it picks up that there is a WKT column, and does the right thing.

I can't vouch for its robustness, but the sample you gave works fine:

id|wkt
1|POLYGON((571178 6337246,571178 6402217,598061 6402217,598061 6337246,571178 6337246))

enter image description here


No Plugin needed

In QGIS deploy a "Virtual Layer" through Layer > Add Layer > Add/Edit Virtual Layer....
In the Query window simply paste the following expression:

SELECT ST_GeomFromText('POLYGON((571178 6337246,571178 6402217,598061 6402217,598061 6337246,571178 6337246))')

or with an SRID code

SELECT ST_GeomFromText('POLYGON((571178 6337246,571178 6402217,598061 6402217,598061 6337246,571178 6337246))', 4326)

The result might look like this

Result


References:

  • PostGIS | ST_GeomFromText
  • Wikipedia | Well-known text representation of geometry