Is it possible to dock QGIS attribute table on the right?

I know it is possible to display it on top and bottom, but for my project it would be better to dock it on right (or left) side.


2 Answers 2


Agree with @JochenSchwarze that it makes sense to have it (and thanks for making it a feature request).

Saying that, it is possible to do it with a bit of Python.

  1. Make sure the Open attribute table in a dock window setting is enabled from the menubar:

    Settings > Options > Data Sources > Feature attributes and table > Open attribute...
  2. Restart QGIS and then open both the Python Console (Plugins > Python Console or press Ctrl+Alt+P) and the Attribute Table of your selected layer.

  3. Then type the following into the Python Console:

    from PyQt4.QtCore import Qt
    from PyQt4.QtGui import QApplication
    attrTables = [d for d in QApplication.instance().allWidgets() if d.objectName() == u'AttributeTable']
    iface.addDockWidget(Qt.RightDockWidgetArea, attrTables[0])

Your attribute table should now be docked to the right:

Attribute table

And if you want to dock it to the left, replace

iface.addDockWidget(Qt.RightDockWidgetArea, attrTables[0])


iface.addDockWidget(Qt.LeftDockWidgetArea, attrTables[0])
  • 1
    Can we agree on that it IS impossible to a 'normal' user expecting it to work via drag and drop and for shure it IS possible if one knows about python, wich in most cases cannot be taken for granted (Saying this is, I daresay, like saying "It is possible to order a meal in Shanghai with a bit of chinese") ;-) Commented Jun 2, 2016 at 12:38
  • 1
    @JochenSchwarze - Haha! Yes completely agree that this is not a 'normal method' at all! Would be a nice feature to implement as drag-and-drop ;)
    – Joseph
    Commented Jun 2, 2016 at 12:43

Seems impossible at the moment. But I strongly agree that it makes sense. I have just started a feature request in the QGIS issue tracker https://hub.qgis.org/issues/14941

  • 1
    Was just fixed: github.com/qgis/QGIS/commit/… hope this answers the question? ;-) Commented Jun 14, 2016 at 8:30
  • I believe it does! In which case, your answer should be accepted =)
    – Joseph
    Commented Jun 14, 2016 at 8:58
  • If I have Qgis installed, I have to reinstall? Commented Jul 4, 2016 at 23:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.