logo
search
Others

How to Create a Mailto Hyperlink with Encoded Spaces in SharePoint

Khadija KhanKhadija Khan Sep 30, 2026 868 views

Question details

The user needs to create a functional mailto hyperlink in SharePoint that includes item URLs and encoded spaces without breaking the link structure.

How to Create a Mailto Hyperlink with Encoded Spaces in SharePoint
Product
SharePoint
Device & OS
not provided
Scenario
Adding a mailto hyperlink containing spaces into a SharePoint list item or generating it dynamically via JSON column formatting.
Observed behavior
Mailto links containing item URLs and encoded spaces are interpreted incorrectly by SharePoint, causing the hyperlink to break and fail to open the email client with the intended populated data.
Before you start

Verify whether you are adding the mailto link directly into a standard SharePoint list item's rich text field or generating it dynamically using JSON column formatting, as the encoding requirements differ between the two methods.

Solution 1Recommended

Format Mailto Links Using JSON Column Formatting

Use this method if your mailto link is generated dynamically within a SharePoint list column.

JSON column formatting allows you to build dynamic mailto links referencing other column values. However, failing to strictly encode spaces and special characters within the JSON structure will cause the browser to truncate the hyperlink.

1
Identify the column

Navigate to your SharePoint list, click on the column header where you want the mailto link to appear, and select 'Column settings' followed by 'Format this column'.

2
Apply JSON formatting

Click 'Advanced mode' at the bottom of the formatting pane to reveal the raw JSON editor.

3
Handle space encoding

Ensure you are using `%20` for spaces in the subject or body parameters of the mailto URL string in your JSON code (e.g., `mailto:user@example.com?subject=Report%20Update`). Avoid using standard unencoded spaces.

4
Save and test

Click 'Save' at the bottom of the pane, then click the newly formatted list item to ensure it successfully opens your default email client with the correct spacing.

Format Mailto Links Using JSON Column Formatting
Dynamic Values: If you are appending dynamic column values to the mailto link (like `[$Title]`), you may need to use expressions to ensure spaces within those column values are also properly encoded.
Free Microsoft Office alternative

Looking for a Lightweight Office Suite? Try WPS Office

While SharePoint handles your team collaboration and list management, WPS Office provides a lightweight, highly compatible alternative for your daily document, spreadsheet, and presentation needs. It fully supports Microsoft Office file formats and offers a seamless user experience.

  1. 1. Download WPS Office: Visit the official WPS website and download the free installation package for your operating system.
  2. 2. Install the software: Run the installer and follow the simple on-screen instructions to complete the setup.
  3. 3. Open and edit your files: Launch WPS Office to instantly open, edit, and save your existing Microsoft Office documents.
Fully compatible with Microsoft Word, Excel, and PowerPoint formats.Free and lightweight, ensuring smooth performance even on older devices.Create and manage professional documents that can be easily shared via SharePoint.Familiar user interface with zero learning curve for Office users.
microsoft office alternative - wps office

Frequently Asked Questions

Why does my SharePoint mailto link break when it contains spaces?

SharePoint and web browsers interpret unencoded spaces as the end of a URL. To prevent the link from breaking, spaces must be explicitly encoded as `%20` within the mailto string.

How do I encode spaces in a JSON column format for SharePoint?

In your JSON configuration, manually replace all spaces within the subject or body parameters of your `mailto:` URL with `%20`. Do not use standard spacebar spaces in the URL string itself.

Does SharePoint support advanced mailto parameters like CC or BCC?

Yes, SharePoint supports standard mailto parameters. You can append `&cc=email@example.com` or `&bcc=email@example.com` after the subject, ensuring all spaces in any added parameter are also properly encoded.