Encoding functions
Usage:
bin(<expression>)bin returns a string containing the binary representation of its argument.
Examples:
-- get the binary representation of 1bin(1)-- get the binary representation of a string`bin('abc')Usage:
hex(<expression>)hex returns a string containing the hexadecimal representation of its argument.
Examples:
-- get the hexadecimal representation of 1hex(1)-- get the hexadecimal representation of a string`hex('abc')Was this helpful?
- Resources
- API
- New to Cloudflare?
- Directory
- Sponsorships
- Open Source
- Support
- Help Center
- System Status
- Compliance
- GDPR
- Company
- cloudflare.com
- Our team
- Careers
- © 2025 Cloudflare, Inc.
- Privacy Policy
- Terms of Use
- Report Security Issues
- Trademark