--- title: "right-trim()" slug: "string-right-trim" updated: 2026-08-17T08:12:48Z published: 2026-08-17T08:12:48Z canonical: "docs.lobstersoftware.com/string-right-trim" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # right-trim() This function removes all non-printable characters and spaces (whitespaces) from the right side of text **a**. ## Parameters | Parameter | Description | | --- | --- | | a | Text | ## Examples Spaces and other whitespaces are represented as underscores here. | Parameter a | Result | | --- | --- | | text | text | | __text__ | text__ |