---
title: "What is the N string prefix in SQL Server?"  
description: "What is the N string prefix in SQL Server?"  
author: "Sandra Emily"  
published: 2024-01-14  
updated: 2025-01-07  
canonical: https://www.mindstick.com/forum/160560/what-is-the-n-string-prefix-in-sql-server  
category: "mssql server"  
tags: ["mssql server", "sql server", "sql"]  
reading_time: 1 minute  

---

# What is the N string prefix in SQL Server?

What is the N [string](https://www.mindstick.com/articles/1527/string-split-in-c-sharp) prefix in [SQL Server](https://www.mindstick.com/articles/12999/what-is-table-valued-function-in-sql-server)?

## Replies

### Reply by Khushi Singh

In [SQL](https://www.mindstick.com/articles/13115/types-of-keys-in-sql-or-oracle-database) [Server](https://www.mindstick.com/articles/43769/what-is-serverless-architecture-is-it-worth-switching-over), an `N` string prefix is used to distinguish between Unicode and non Unicode strings. It also helps in making sure that the string is of unicode that is NVARCHAR rather than non unicode that is VARCHAR. This is useful where there are large amounts of data that contain multilingual, or other characters not normally included in ASCII chart.

**Key Points:**\
N Prefix:

- The N stands for “**National”** or “**Unicode**”.
- When used, it will be treated as Unicode; it is used in an NVARCHAR column or variable/format to store it.\

## Usage:

- Put the N before the string literal in SQL.

Example:

```plaintext
SELECT N'Hello World';  -- Unicode string
```

Hope it helps!


---

Original Source: https://www.mindstick.com/forum/160560/what-is-the-n-string-prefix-in-sql-server

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
