텍스트 ↔ Base64 즉시 변환. JWT 토큰 디코딩도 가능합니다
Base64는 바이너리 데이터를 64개의 ASCII 문자(A-Z, a-z, 0-9, +, /)로 표현하는 인코딩 방식입니다. 텍스트 기반 프로토콜(이메일, HTTP)에서 바이너리 데이터를 안전하게 전송하기 위해 개발되었습니다.
data:image/png;base64,...// 인코딩
const encoded = btoa('Hello, 테크팁KR');
// 디코딩
const decoded = atob(encoded);
// 한국어(유니코드) 처리
const encodeKR = str => btoa(unescape(encodeURIComponent(str)));
const decodeKR = str => decodeURIComponent(escape(atob(str)));
import base64
# 인코딩
encoded = base64.b64encode(b'Hello, TechTipKR').decode('utf-8')
# 디코딩
decoded = base64.b64decode(encoded).decode('utf-8')
# URL-safe Base64
url_safe = base64.urlsafe_b64encode(b'data').decode('utf-8')