This patch enables code-server to use Cascadia Code with italic and cursive support.
It works with offline font files and automatically injects the necessary @font-face rules to properly render italics and cursive glyphs.
code-server running on termux proot-distro (Ubuntu)
- Clone this repository:
git clone https://github.com/delmsyap/code-server-font-patch-cascadia.git
cd code-server-font-patch-cascadia- Cascadia Code font files are located in the
fonts/cascadiafolder next to the script:
fonts/cascadia/
├── CascadiaCode.woff2
└── CascadiaCodeItalic.woff2- Run the patch script. The script automatically detects your code-server installation path:
❯ chmod +x patch.sh
❯ ./patch.sh
[*] Installing existing Cascadia Code fonts
[*] Copying fonts
[*] Backing up workbench.html
[*] Injecting @font-face
[✓] Cascadia Code installed successfully
👉 Add this to settings.json:
{
"editor.fontFamily": "'Cascadia Code', monospace",
"editor.fontLigatures": "'calt', 'ss01'"
}The script will copy the fonts to the code-server _static folder, inject the CSS, and back up workbench.html. No manual editing of workbench.html or hardcoding of paths is required.
After installation, configure your editor in settings.json to enable Cascadia Code with cursive italics:
{
"editor.fontFamily": "'Cascadia Code', monospace",
"terminal.integrated.fontFamily": "'Cascadia Code', monospace",
"editor.fontLigatures": "'calt', 'ss01'"
}'calt', 'ss01' enables Cascadia Code’s cursive italic glyphs.
Optional: add 'ss02' for additional stylistic flourishes.
-
Open code-server and check comments or italic tokens — letters like f, k, y should appear curvy/cursive.
-
Open Developer Tools → Network → Font to confirm:
CascadiaCode.woff2 → 200 OK
CascadiaCodeItalic.woff2 → 200 OK- or test it directly with
curlto confirm if fonts are loaded successfully:
❯ curl -I http://localhost:8080/_static/src/browser/media/fonts/CascadiaCode.woff2
HTTP/1.1 200 OK
Accept-Ranges: bytes
Cache-Control: public, max-age=0
Last-Modified: Thu, 29 Jan 2026 12:36:22 GMT
ETag: W/"356c8-19c09c131d9"
Content-Type: font/woff2
Content-Length: 218824
Date: Thu, 29 Jan 2026 17:41:49 GMT
Connection: keep-alive
Keep-Alive: timeout=5
❯ curl -I http://localhost:8080/_static/src/browser/media/fonts/CascadiaCodeItalic.woff2
HTTP/1.1 200 OK
Accept-Ranges: bytes
Cache-Control: public, max-age=0
Last-Modified: Thu, 29 Jan 2026 12:36:22 GMT
ETag: W/"27010-19c09c131d1"
Content-Type: font/woff2
Content-Length: 159760
Date: Thu, 29 Jan 2026 17:47:12 GMT
Connection: keep-alive
Keep-Alive: timeout=5Fonts are served offline — no Google Fonts dependency.
Works on any Linux system or Termux environment.
Safe for re-use — workbench.html is backed up before CSS injection.

