There's one question in SO I'm planning to answer with a really long answer. While I'm still baking my post, these questions dawned to me:

  1. What is the maximum character length of a post?

  2. How many links can I include, at most?

  3. How about the number of images?

  4. What is the character limit on the question title?

  5. Do the limits on questions apply to answers as well, or do they have different ceilings?

  • Are you trying to do a really massive self-answered Q/A? – Mysticial Apr 14 '13 at 2:44
  • Nope, it's not a self-answered Q/A. It's an old question I stumbled upon, but doesn't have an accepted answer. – Ronixus Apr 14 '13 at 2:51
up vote 38 down vote accepted

The maximum length of a post, question or answer, on Stack Overflow is 30,000 characters. This includes markdown and any other formatting. The limit on the question title is 150 characters.

I don't believe there are any upper limits on the number of links and images. I challenge you to make a post so heavy on links and images that we're tempted to add some. ;)

  • 4
    I 'd write a script to do that, pulling data from Google. :) I'm joking... Maybe we need a spammers stack. – beppe9000 Jan 9 '15 at 20:48
  • But in SEDE the title length is 250 and that limit seems to be reduced, as found out by a user on MSO where I provided this answer and the query I used the validate title length. – rene Sep 13 '15 at 14:12
  • 2
    Because it is interesting, I found that there are actually about 950 posts on Stack Overflow that are over this soft-limit of 30,000 characters, with the biggest being this answer, which is currently 53,383 characters long. Cross-reference soft-limit. – Bob Oct 10 '15 at 12:27
  • @rene I saw your MSO post about the title limits. Very interesting! I found an equally awkward situation with post bodies (see above comment). The datatype for post bodies in SEDE is nvarchar(max), 2GB worth of character data. Not sure if such posts can be edited without shortening them first. – Bob Oct 10 '15 at 12:58
  • @Bob keep in mind that SEDE isn't an exact copy of the production database so it is all more or less educated guessing and when blatantly wrong Anna will be the first to correct me. For posts.body you can't follow the same reasoning because what is stored is the html result after markdown parsing while the 30K limit is for raw markdown. The html is almost guaranteed to take more characters. However if you take the len(text) of the posthistory table for type 2 and 4 you'll find that the max=30K. The raw post body is stored there. – rene Oct 12 '15 at 18:39
  • 2
    "I don't believe there are any upper limits on the number of links and images" For users with less than 10 reputation there are limits, the limit is 2 links and no images. – Donald Duck Jun 7 '17 at 10:25
  • Is this still correct or has this changed ? Has the limit been changed since when the answer was posted ? – Sergiy Kolodyazhnyy Jan 20 at 23:46
  • @SergiyKolodyazhnyy No changes I can think of off the top of my head. Why do you ask? – Adam Lear Jan 22 at 18:16
  • @AdamLear I had this same question on another SE site, and an answer there pointed to this one, but it's been posted a few years ago. Just curious whether this information is still valid and if the answer on my SE site should be accepted. Besides, I typically write lengthy answers which involve python or shell scripts, as well, so I need to know the limits – Sergiy Kolodyazhnyy Jan 22 at 18:19
  • @SergiyKolodyazhnyy Fair enough. Yeah, these should still be correct. – Adam Lear Jan 22 at 18:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .