In ancient times, people took numerical symbolism pretty damn seriously, like shivers-down-your-spine level seriously. In that regard, no number has gained more infamy, notoriety and legend than the number 666, not even the number 42! The Number of the Beast, forever associated with the devil and his many forms. The origin of this, or the reason why this number is related to all things satanic, is a little complicated however, and is something that's been hotly debated since, well, forever.
The Number of the Beast is a term in the Book of Revelation, of the New Testament, and the number itself is 666.
This number is associated with the Beast of Revelation in chapter 13, and is described in the passage of Revelation 13:15–18, being mentioned only once in verse 18. The exact words are, "This calls for wisdom: let the one who has understanding calculate the number of the beast, for it is the number of a man, and his number is 666."
While the description of the 'Beast' does match that of Satan, the book also says that it is the number of man, which leads to a certain degree of confusion.
Another interpretation in which this number show up is in the relation to Solomon and his treasury. "The weight of gold that came to Solomon in one year was six hundred sixty-six talents of gold."
Another explanation could be that the Bible associates the number 6 with man, and a triple repetition of this number means this beast represents a government based on human authority as opposed to God's authority.
It's difficult, and probably a little pointless at this juncture, to figure out exactly what the number denotes, or how it originated. In fact, it's interesting to note that in some early biblical manuscripts and critical editions of the Greek text, the number is cited as 616! Either way, nobody really knows what the exact meaning of the number is, only that common perception of it isn't likely to change any time soon.