# Graphviz VIEWER with native Mac UI

**URL:** <https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566>\
**Category:** Help\
**Created:** [April 14, 2023, 3:31am UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566 "2023-04-14T03:31:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![halloleo](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/halloleo/32/1066_2.png) [@halloleo](https://forum.graphviz.org/u/halloleo)\
**Post date:** [April 14, 2023, 3:31am UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566/1 "2023-04-14T03:31:11Z")

</div>

Hey, I’m doing a bigger project with Graphviz. I write my dot code in an editor and would like to use an external Graphviz **Viewer** to see how the result looks.

At the moment I have a little script which converts dot code to SVG and then shows the SVG in a browser, but a dedicated app might be more convinient.

So, I’m _not_ looking for a Graphviz _Editor_ just a Viewer, and – please! – no X Window UI: It’s not that great on macOS.

Any suggestion of a viwer with a mac-native UI would be greatly appreciated.

---

<div class="post-metadata">

**Author:** ![mark](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/mark/32/84_2.png) [@mark](https://forum.graphviz.org/u/mark)\
**Post date:** [April 14, 2023, 7:49am UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566/2 "2023-04-14T07:49:53Z")

</div>

A simple built-in solution Consider using dot -Tpdf which outputs pdf, and then you can open the result in Preview.app, which is pretty slick for zooming in and out.

---

<div class="post-metadata">

**Author:** ![schmoo2k](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/schmoo2k/32/29_2.png) [@schmoo2k](https://forum.graphviz.org/u/schmoo2k)\
**Post date:** [April 14, 2023, 8:02am UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566/3 "2023-04-14T08:02:12Z")

</div>

vscode with a graphviz extension (not sure if it really counts as mac native?): [Search results - graphviz | Visual Studio Code , Visual Studio Marketplace](https://marketplace.visualstudio.com/search?term=graphviz&target=VSCode&category=All%20categories&sortBy=Relevance)

---

<div class="post-metadata">

**Author:** ![smattr](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/smattr/32/85_2.png) [@smattr](https://forum.graphviz.org/u/smattr)\
**Post date:** [April 14, 2023, 4:04pm UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566/4 "2023-04-14T16:04:28Z")

</div>

I have never used it, but Graphviz.app is a GUI app that ships with Graphviz and claims to be able to do this.

---

<div class="post-metadata">

**Author:** ![hraftery](https://sea2.discourse-cdn.com/graphviz/user_avatar/forum.graphviz.org/hraftery/32/1448_2.png) [@hraftery](https://forum.graphviz.org/u/hraftery)\
**Post date:** [May 15, 2024, 4:57am UTC](https://forum.graphviz.org/t/graphviz-viewer-with-native-mac-ui/1566/5 "2024-05-15T04:57:58Z")

</div>

I had to sign up to report my findings on this topic. It seems, today, that:

- installing via **MacPorts** (ie. `sudo port install graphviz`) installs a subport called [graphviz-gui](https://ports.macports.org/port/graphviz-gui/) which installs the genuine app, v9.0.0 (8 months old). It’s not clear to me how that’s achieved from the [portfile](https://github.com/macports/macports-ports/blob/master/graphics/graphviz/Portfile), and I no longer have MacPorts installed to check.
- on the other hand, installing via **HomeBrew** (ie. `brew install graphviz`) does not. Although you do get version v11.0.0 (the latest).
- there was [an effort](https://gitlab.com/graphviz/graphviz/-/issues/2120) two years ago to put it on the **AppStore** , that didn’t quite make it.
- there was a long and [successful effort](https://gitlab.com/graphviz/graphviz/-/merge_requests/3489) to get the build system to create a **pkg** when building from source, which installs Graphviz.app in the /Applications folder.
- **PixelGlow** have their [own GUI](http://www.pixelglow.com/graphviz/) for graphviz, but it hasn’t been touched for a decade or more.
- there’s even a **QuickLook** [project](https://github.com/besi/quicklook-dot) which requires `dot` to be on the path.

I stumbled across [`xdot`](https://formulae.brew.sh/formula/xdot#default) (which is [this Python script](https://github.com/jrfonseca/xdot.py), not the [custom Graphviz language](https://graphviz.org/docs/attr-types/xdot/) by the same name) and it’s working just fine for me. I can now run `xdot myfile.gv` to get an interactive viewer (with node highlighting), in about the same time as dot takes to create a PDF.
