urlencode

The urlencode operation encodes the input value into a URL-safe format. It converts special characters (spaces, diacritics, symbols) into percent-encoded sequences (%xx) so that the result can safely be transmitted as part of a URL or query string.

How it works

  • Input – any string.
  • Output – the URL-encoded representation of the string.
  • Encoding rules:
    • Spaces are converted to +.
    • Non-alphanumeric characters are replaced with % followed by two hex digits.
    • Letters, numbers, and – _ . ~ remain unchanged.

Examples

InputOutput
hello worldhello+world
ahoj světe & goahoj+sv%C4%9Bte+%26+go
info@example.cominfo%40example.com
+420797992279%2B420797992279

Usage in PalDock

Use urlencode when you need to:

  • Safely include values in query parameters of URLs.
  • Normalize input before building redirect links.
  • Prevent issues when passing special characters (&, @, +, spaces) to external APIs.
  • Encode user-generated content (names, messages) for reliable transmission.

Best Practices

  • Always apply urlencode when concatenating values into URLs.
  • Use together with urldecode for round-trip transformations.
  • Validate input if you expect only safe characters; unnecessary encoding may reduce readability.
  • Remember that spaces become +. If the receiving system requires %20 instead, consider rawurlencode instead of urlencode.

References

Insights that
helps you grow

  • Release notes 2025/12/19
    We added country-based categorization. You can now categorize offers, integrations, and other items by a specific country, or keep them global across all markets. We also…
  • Release notes 2025/12/17
    More flexible lead rejection: based on validation rules, filters, or pingtree sales results, by source (iframe, API) or by partner (include / exclude). It is now possible to…
  • Case study: How Lender Orka Ventures Scaled Affiliate Operations
    Orka Ventures, an online lending group that wanted to scale fast across countries and onboard affiliates quickly. Their custom affiliate API and tracking layer soon…