36

I am currently running macOS Sierra (10.12.6) and was wondering if there is an easy way to format code (like there is for Title, Heading, etc.) in Apple's Notes app?

I'm open to any workarounds to achieve this. I would like to have syntax highlighting as you would see in a text editor (like Atom or Sublime).

5 Answers5

39

Notes in macOS High Sierra includes a Monospaced format.

In addition to the existing format types such as Title, Heading and Body, there is a new format named ‘Monospaced’. This format is a variation of the Body format but with a monospaced font family.

macOS High Sierra Hidden Features, Notes.app

grg
  • 201,078
  • Is the only way to solve this problem to upgrade to High Sierra? – Jack Moody Jan 12 '18 at 22:02
  • 9
    This formats wehole paragraph. Cannot select a single word and format as monospace, quite annoying. – Oleg Jan 04 '19 at 11:48
  • 4
    WARNING: Notes cannot handle code, even in Mojave! It will replace certain characters inside your code (' changes to ´ etc.), add hidden line breaks etc., in sum it's unusable for code documentation. – Sliq Feb 01 '19 at 09:54
  • 1
    At least it can be used as a workaround, I really don't want to move all my things to Evernote, THB. – Ender Sep 01 '20 at 13:52
  • 1
    @Oleg It seem you can select a single word and format it by bypassing default font options and choosing a font from Fonts menu (Command+T or Format > Font > Show Fonts. I'm using Menlo font.) – Dmitry Dec 23 '22 at 21:14
  • This is the best answer. All others direct you to install a separate app, but the questions asks for how to do this in Apple Notes specifically – user1205577 Jul 26 '23 at 14:22
9

Note: I am in no way connected to any of these software.

Free Options

Boostnote is an open source project for writing notes with syntax highlighting. This is a good free alternative to using the native Notes app if you aren't against downloading an additional application.

Boost Application

Paid Options

Quiver provides features like LaTeX support, syntax highlighting, customizable themes, cloud syncing, and version control. As of writing this, it costs $9.99.

Quiver app

Bear provides syntax highlighting, easy exports (to PDF, .docx, HTML, JPG, etc.), multiple themes, and syncing through iCloud. As of writing this, it costs $1.49 per month (if paid monthly) or $14.99 per year (if paid annually). If paying monthly, you will get a free one week trial. If paying yearly, you will get a free one month trial.

Bear app

  • Boostnote doesn't seem to be free anymore. They offer a 14-day trial, after which you have to pay or you won't be able to add/edit notes anymore. – Alessandro Benassi Feb 25 '23 at 11:35
5

Joplin

I've been using Joplin for a month. And it meets my requirements (I'm a developer).

  • Markdown editor [WYSIWYG]
  • Pasting image from clipboard
  • Dark mode (Also custom css support is there)
  • Export as PDF, Html etc
  • Dropbox sync
  • Tagging the documents

And yes, The UI is not intuitive, but the exported doc does look good.


Update [Sep, 2020]

I tried Obsidian and Typora.

Obsidian

Prefer if you're doing research work.

Some cool features

  • Easy Document linking and ability to update display text at ease
  • Keeps files & attachment in a so-called vault
  • Mind map to visualize how documents interact with each other
  • Presentation [Enable it in plugin section]
  • Theme support
  • Document Tagging

Cons:

  • WYSIWYG experience is not good
  • Image handling resizing not possible and copying the image also troublesome

Typora - current favorite

I think, I'll settle here. Unlike the other apps above this feels native. The other apps are built over (Chrome?!) electron framework?

Pros

  • Awesome WYSIWYG experience
  • Themes are looking good [It will get closer to Bear's UI]
  • Smoother experience with inserting/resizing & copying the image

Cons

  • Document handling is like file/folder open. Keep a separate folder for docs and set the same as startup folder in preference.
nohillside
  • 100,768
Mahendran
  • 153
  • 1
    Since Apple notes does not support inline or block code syntax, and Evernote appears to have removed support, I was desperate for an alternative. Thanks for link to Joplin. I like that it has cloud sync and is based around Markdown. Code formatting works as desired with either inline or block based. – Small Talk Jan 25 '22 at 16:29
4

Notion offers markdown features on steroids, with commands

enter image description here

mindlid
  • 149
  • 5
2

For those stumbling across this questions in macOS Sonoma times, at the moment Notes improved on "Monospaced". Now it's "Monostyled" which creates nice code-block style zone and doesn't attempt to auto-correct formatting there. Not quite mark-down, but works great for small cheat sheets and code snippets.

enter image description here