[GH-ISSUE #1541] Query Parameters Incorrectly Appended to URL. #489

Closed
opened 2026-03-16 15:38:16 +03:00 by kerem · 0 comments
Owner

Originally created by @JayceDugan on GitHub (Mar 16, 2021).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/1541

Describe the bug
Query parameters when added to a request are appended without trimming white space and are not URL encoded.

To Reproduce
Steps to reproduce the behaviour:

  1. Start a new GET request.
  2. Click on the parameters tab.
  3. Add a parameter key and value of type Query with white space or a space between two words.

e.g:

Parameter: Lorem Ipsum
Value: Dolor Amet

  1. Review the parameters appended to the request URL. The parameters are NOT URL encoded and all white space is still visible and unchanged.

Expected behaviour

Query parameters should be URL encoded, resulting in white space being trimmed & special characters being replaced with the relevant UTF8 encoding of the relevant character.

The space character is excluded because significant spaces may disappear and insignificant spaces may be introduced when URI are transcribed or typeset or subjected to the treatment of word- processing programs. Whitespace is also used to delimit URI in many contexts.

From RFC 2936, section 2.4.3:

The space character is excluded because significant spaces may disappear and insignificant spaces may be introduced when URI are transcribed or typeset or subjected to the treatment of word- processing programs. Whitespace is also used to delimit URI in many contexts.

Screenshots
N/A

Desktop (please complete the following information):

  • OS: Linux
  • Browser: Chrome 88.0.4324.182 (Official Build) Arch Linux (64-bit)
  • User agent | Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.182 Safari/537.36

Smartphone (please complete the following information):
N/A

Additional context
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURI
https://www.ietf.org/rfc/rfc2396.txt

Originally created by @JayceDugan on GitHub (Mar 16, 2021). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/1541 **Describe the bug** Query parameters when added to a request are appended without trimming white space and are not URL encoded. **To Reproduce** Steps to reproduce the behaviour: 1. Start a new `GET` request. 2. Click on the parameters tab. 3. Add a parameter key and value of type `Query` with white space or a space between two words. e.g: Parameter: `Lorem Ipsum` Value: `Dolor Amet` 4. Review the parameters appended to the request URL. The parameters are **NOT** URL encoded and all white space is still visible and unchanged. **Expected behaviour** Query parameters should be URL encoded, resulting in white space being trimmed & special characters being replaced with the relevant UTF8 encoding of the relevant character. The space character is excluded because significant spaces may disappear and insignificant spaces may be introduced when URI are transcribed or typeset or subjected to the treatment of word- processing programs. Whitespace is also used to delimit URI in many contexts. From [RFC 2936](https://www.ietf.org/rfc/rfc2396.txt), section 2.4.3: > The space character is excluded because significant spaces may disappear and insignificant spaces may be introduced when URI are transcribed or typeset or subjected to the treatment of word- processing programs. Whitespace is also used to delimit URI in many contexts. **Screenshots** N/A **Desktop (please complete the following information):** - OS: Linux - Browser: Chrome 88.0.4324.182 (Official Build) Arch Linux (64-bit) - User agent | Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.182 Safari/537.36 **Smartphone (please complete the following information):** N/A **Additional context** https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURI https://www.ietf.org/rfc/rfc2396.txt
kerem closed this issue 2026-03-16 15:38:21 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#489
No description provided.