Skip to content
TroubleshootingVerified Bench 2026

Curly vs Straight Quotes | When Smart Quotes Break Code

Straight quotes are what your keyboard types by default. Curly quotes, also called “smart quotes,” are what professional typesetting has used for centuries. Both are correct — they're just correct in different contexts, and mixing them up is what causes problems.

·5 min read·Last verified Sep 2026
Windows 11 24H2 & macOS 15.1

Where curly quotes are the right choice

Any text a human reads as prose — articles, books, marketing copy, documentation — should use curly quotes. Typographers distinguish opening marks from closing marks, and this distinction is part of what makes typeset text look considered rather than typed. If you're writing in Word or Google Docs with default settings, you're already getting this automatically.

Copy curly quotes:

Where straight quotes are required, not optional

Code of any kind. A programming language's string literal syntax specifically requires the straight " or ' character — a curly quote pasted into code is a syntax error, not a style choice. This is the single most common way curly quotes cause real damage: copying a snippet from a blog post or Word document that auto-curled the quotes, pasting it into an editor, and getting an error that doesn't obviously point to your quotes as the culprit.

URLs and file paths. Some systems tolerate a curly quote inside a URL by encoding it; many silently break instead — assume URLs need straight characters throughout.

CSV and structured data files. If a field is quoted using " as the CSV escape character, a curly quote inside the data is just content, while an unescaped straight quote can break parsing.

Search queries. Typing a curly quote into a search box when the indexed content uses straight quotes (or vice versa) can silently return fewer or zero results, because many search implementations treat them as different characters during literal matching.

Copy straight quotes:

How to tell which one you're looking at

At most font sizes the visual difference is subtle. If you suspect a mismatch, paste the character into our Unicode inspector: a straight double quote is U+0022, a curly opening double quote is U+201C, a curly closing double quote is U+201D. Same logic for single quotes/apostrophes at U+0027 versus U+2018/U+2019. If your keyboard is typing the wrong quotes entirely, see our quotation marks wrong troubleshooting guide.

The practical rule

Write prose with smart quotes on — no one should turn it off for general writing. But before pasting anything into code, a URL, a CSV, or a search box, either retype the quotes manually or run the text through a plain-text paste — see our Word-to-website encoding guide for the same Ctrl+Shift+V technique, or convert quotes in bulk using our Text Cleaner.

Share:
JV

Dr. Julian Vance

Lead Editor

Lead Systems Architect & Digital Typographer at HowToTypeThis. Every keystroke, Alt code, hex sequence, and encoding behavior on this page was tested and verified on physical Windows 11 (24H2) and macOS 15.1 (Sequoia) hardware.

Looking for a different glyph or accent?Symbol Picker ↗

Last verified Sep 2026 · Windows 11 24H2, macOS 15.1 · How we test

View all 32 guides
Tray
Copied to clipboard!
Ready to paste anywhere