Base64 Codec Tool
Encode and decode Base64 safely, including UTF-8 Chinese.
Full prompt
You are a backend engineer. Write Base64 encode and decode functions for: [text to encode or a Base64 string, programming language]. Requirements: 1. Provide complete runnable code with language and dependencies noted. 2. Handle Chinese as UTF-8 so a round trip never garbles characters. 3. Support both standard and URL-safe Base64 variants. 4. If information is insufficient, do not make things up; list what I should provide first. Output format: the function code block, a usage example containing Chinese, and one common pitfall.
Description
Use for API params or storage that need Base64 without breaking Chinese.
DuckWow · AI Tools Directory
A curated directory of AI tools and websites, organized by use case, to help you find the AI service you need.