Writing & StyleStyle guide

Escaping Special Characters in No-Loc Strings

Escaping Special Characters in No-Loc Strings records a distinct Microsoft Learn authoring convention and keeps it scoped to that documentation environment rather than presenting it as a universal writing rule.

Quick answer

Inside a Microsoft Learn `:::no-loc` string, escape special characters with a backslash when needed—for example, escape quotation marks embedded in the directive’s quoted text.

Key details

Core Issueescaping special characters inside no-loc directives
RegisterMicrosoft Learn technical documentation

Important caveats

Scope Boundary

This page covers escaping inside the Learn `no-loc` extension; ordinary Markdown escaping and YAML `no-loc` metadata have different syntactic contexts.

Further guidance

Content

Inside a Microsoft Learn `:::no-loc` string, escape special characters with a backslash when needed—for example, escape quotation marks embedded in the directive’s quoted text.

Purpose

Keep Microsoft Learn source readable, accessible, reusable, and predictable while following current contributor-platform conventions.

Sources and evidence

Sources are shown with the role they play in this guide. Historical or style-sensitive claims are kept within the evidence boundary described above.

  1. Markdown reference for Microsoft Learn — Contributor guide (opens in a new tab)Microsoft · Current Microsoft Learn contributor reference for Markdown authoring, including headings/navigation, conceptual images and icons, includes, lists/checklists, nonlocalized strings, alerts, comments, tables, and other Learn extensions.

Related guides

Writing & Style

Escaping Angle Brackets in Learn Markdown

Escaping Angle Brackets in Learn Markdown records a distinct Microsoft Learn authoring convention and keeps it scoped to that documentation environment rather than presenting it as a universal writing rule.

Writing & Style

Escaping Underscores in Microsoft Learn Image Alt Text

Escaping Underscores in Microsoft Learn Image Alt Text records a distinct Microsoft Learn authoring convention and keeps it scoped to that documentation environment rather than presenting it as a universal writing rule.

Writing & Style

Using Nonlocalized Strings in Learn Markdown

Using Nonlocalized Strings in Learn Markdown records a distinct Microsoft Learn authoring convention and keeps it scoped to that documentation environment rather than presenting it as a universal writing rule.

Explore the topic