# Add a scale bar to a viewport

OVITO currently has no built-in function to add a scale to an image, but it is possible to use an OVITO Python script to paint a custom scale bar on top of a viewport or a rendered image.

For this you have to add a Python script overlay to the viewport where you want to display a scale bar. You can then copy/paste the example Python script from this page into the script field of the viewport overlay.