Base64 인코딩 · 디코딩Base64 Encode · Decode

텍스트와 파일을 즉시 변환합니다. 한글 등 UTF-8 문자를 지원하며, 입력한 내용과 파일은 서버로 전송되지 않고 브라우저 안에서만 처리됩니다.Convert text and files instantly. UTF-8 characters such as Korean and emoji are supported, and everything you enter is processed in your browser — nothing is sent to a server.

Base64란?What is Base64?

Base64는 바이너리 데이터를 영문 대소문자, 숫자, +, / 64개 문자로 표현하는 인코딩 방식입니다. 이메일 첨부파일, HTTP 기본 인증 헤더, 데이터 URL, JWT 토큰 등에 널리 쓰입니다.Base64 is an encoding that represents binary data using 64 characters: upper- and lowercase letters, digits, +, and /. It is widely used for email attachments, HTTP Basic authentication headers, data URLs, and JWT tokens.

  • 암호화가 아닙니다. 누구나 쉽게 디코딩할 수 있으므로 비밀번호 보호 용도로 쓰면 안 됩니다.It is not encryption. Anyone can decode it easily, so never use it to protect passwords.
  • 인코딩하면 데이터 크기가 약 33% 늘어납니다. (3바이트 → 4문자)Encoding increases data size by about 33% (3 bytes → 4 characters).
  • URL-safe 형식은 + 대신 -, / 대신 _를 써서 URL이나 파일 이름에 그대로 넣을 수 있습니다. JWT가 이 형식을 사용합니다.The URL-safe variant uses - instead of + and _ instead of /, so it can go directly into URLs and file names. JWTs use this variant.
  • 디코딩할 때는 일반 형식, URL-safe 형식, 패딩 유무, 줄바꿈, data: URL을 자동으로 인식합니다.When decoding, standard and URL-safe variants, missing padding, line breaks, and data: URLs are detected automatically.
  • 디코딩 결과가 이미지나 PDF 같은 바이너리 데이터이면 형식을 판별해 미리보기와 파일 저장을 제공합니다.If the decoded result is binary data such as an image or PDF, the format is detected and a preview and file download are offered.

자주 쓰는 예시Common Examples

HTML에 이미지 직접 넣기 — 파일 탭에서 이미지를 data URL로 변환한 뒤 <img src="data:image/png;base64,...">처럼 사용하면 별도 이미지 파일 없이 표시됩니다. 작은 아이콘에 적합합니다.Embed an image directly in HTML — convert an image to a data URL in the File tab and use it like <img src="data:image/png;base64,..."> to display it without a separate image file. Great for small icons.

HTTP 기본 인증 헤더 만들기 — 아이디:비밀번호를 인코딩해 Authorization: Basic <결과> 형식으로 보냅니다. 예: user:pass → dXNlcjpwYXNzBuild an HTTP Basic auth header — encode username:password and send it as Authorization: Basic <result>. Example: user:pass → dXNlcjpwYXNz

JWT 내용 확인 — JWT는 점(.)으로 구분된 URL-safe Base64 문자열입니다. JWT 디코더에서 헤더와 페이로드, 만료 시간을 바로 확인할 수 있습니다.Inspect a JWT — a JWT is a set of URL-safe Base64 strings separated by dots. Use the JWT Decoder to see its header, payload, and expiry time.