Text size calculator
Calculate the size of any text in bytes, kilobytes and megabytes. Check database field, API, SMS and upload limits, including UTF-8 characters. Free.
| Size |
How much space does your text take up?
Characters and bytes aren't the same thing. In UTF-8, the encoding used by almost the entire web, an English letter takes 1 byte, an accented letter like é takes 2, many Asian characters take 3, and most emoji take 4. The text size calculator tells you exactly how big your text is in bytes (B), kilobytes (KB) and megabytes (MB).
That matters whenever a system limits size rather than length: a database column defined in bytes, an API with a maximum payload, a cookie, a push notification, a URL, or an upload field. Text that looks short can still be too large once emoji and special characters are counted.
Paste the text and you'll get the size instantly.
How to use the text size calculator
- Paste or type your text.
- The size updates as you type.
- Read the size. It's shown in B, KB or MB, whichever fits, using 1 KB = 1,024 bytes.
- Trim the text if it's over the limit you're working with.
Examples
Plain English
Input: Hello
Output: 5 B
One byte per letter.
Accented letters
Input: café
Output: 5 B
Four characters, five bytes: é takes 2 bytes in UTF-8.
Emoji
Input: 👍👍👍
Output: 12 B
Three characters on screen, four bytes each.
Non-Latin script
Input: नमस्ते
Output: 18 B
Six characters in Devanagari, three bytes each.
Common uses
- Checking whether text fits a database column or index limit.
- Making sure an API request or webhook payload is under its maximum size.
- Estimating the size of JSON, CSV or log data.
- Checking cookie, header and push notification limits.
- Comparing the size of code before and after minifying.
Tips and things to know
- Emoji and non-Latin scripts use more bytes per character. A 100-character message with emoji can be over 200 bytes.
- Kilobyte conventions vary: some systems use 1 KB = 1,000 bytes, others 1,024 bytes. Check which your platform uses.
- For character and word counts instead of bytes, use the character counter.
- To shrink code, try the HTML minifier, CSS minifier or JS minifier.
Edge cases and limitations
- The result rounds to two decimals and switches unit above 1,024 bytes, so 1,536 bytes shows as 1.5 KB.
- Line breaks count. A line break typed in the box counts as 1 byte; files saved on Windows use 2 per line.
- The count is UTF-8. Systems that store text as UTF-16, like JavaScript string lengths and some databases, report different sizes.
- Invisible characters copied from websites, like non-breaking spaces (2 bytes), are counted even though you can't see them.
Frequently asked questions
How many bytes is one character?
In UTF-8, from 1 to 4 bytes. Basic English letters, numbers and punctuation use 1 byte; accented letters use 2; many CJK characters use 3; most emoji use 4.
What's the difference between characters and bytes?
Characters are what you see; bytes are how the text is stored. Limits on storage or data transfer are usually in bytes.
How many bytes are in a kilobyte?
Either 1,000 (decimal, common in storage marketing) or 1,024 (binary, common in operating systems).
Why is my text bigger than its character count?
It contains characters that need more than one byte in UTF-8, such as accents, symbols or emoji.
Related tools
- Character counter: Count the amount of characters and words of a given text.
- HTML minifier: Minify your HTML by removing all the unnecessary characters.
- Base64 encoder: Encode any string input to Base64.
- JSON validator & beautifier: Validate JSON content and make it looks good.
- File mime type checker: Get details of any file type, such as the mime type or last edit date.
Popular free tools
Create strong, random passwords in one click. Pick the length and include uppercase, lowercase, numbers and symbols. Free, no signup.
Extract every email address from text, HTML, logs or documents in one click and get a clean list with a count. Free online email extractor.
Convert text to UPPERCASE, lowercase, Sentence case, Capital Case, camelCase, PascalCase, snake_case, CONSTANT_CASE, dot.case or param-case. Free.
Look up the DNS records of any domain: A, AAAA, CNAME, MX, NS, TXT and SOA. Check email, SPF, verification and nameserver settings for free.
Create a WhatsApp click-to-chat link with your phone number and a prefilled message. Add it to your site, bio, ads or QR codes. Free wa.me generator.
Enter an IP address to find the host name or domain associated with it through a reverse DNS (PTR) lookup. Free reverse IP lookup tool.