Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7014405
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T22:31:00+00:00 2026-05-27T22:31:00+00:00

I started wondering what is the overall impact of using whitespaces to indent html

  • 0

I started wondering what is the overall impact of using whitespaces to indent html documents.

Why not simply use tabs to indent? Wouldn’t this be more cost-effective: 1 char (\t) vs. example 4 chars (spaces)?

I did little experimenting by converting an asp.net-page to use tabs and compared sizes of rendered markups.
By replacing only one partial view’s white space caused a page of 22kb size to be reduced to 19,4kb -> that’s 12% reduction. Changing all indentation, page ended up allocating 16,7kb – 24% reduction! (used chrome dev tools and Fiddler for verifying)

Is my reasoning sound? Should tabs be used primary for indentation of HTML? Is there any reason to use spaces(such as compatibility with exotic browsers)?

ps. Stackoverflow seems to use spaces too. Converting SO main page to use tabs gave 9% reduction. Is this valid observation? If so, why haven’t they used tabs?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T22:31:00+00:00Added an answer on May 27, 2026 at 10:31 pm

    StackOverflow uses HTTP Compression – when this is turned on, the differences between using spaces versus tabs goes down – a lot.

    You need to run your tests against the compressed versions for reliable results.

    You do have a point though for the cases when a browser does not support the compression schemes the server supports.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

After this conversation I started wondering if it's possible to use that and apply
We've just started looking at using JBehave for acceptance tests and I was wondering
We started using Multi-Master Replication Manager for MySQL, and I am wondering whether it
I've just started using Linq to SQL, and I'm wondering if anyone has any
I was looking at this question and started wondering what does the print actually
This is pretty basic but I was coding and started wondering if there was
Hey, I just started wondering about this as I came upon a code that
just started using Zend Framework and I'm wondering what to do with odd classes
I have started using WebSVN and I'm wondering if there is a correct/propper way
Was playing around a little bit with the TimeSpan class and I started wondering

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.