The ability to block incoming texts to your iPhone liberates you from receiving unwanted messages without having to go through the trouble of changing your mobile number. The ability to block texts on your iPhone is not a native feature, but text-blocking apps are available provided you are willing to jailbreak your iPhone.
The iPhone's OS is incapable of blocking unwanted text messages, and there are no text-blocking applications available from the iStore. AT&T sponsors a program called Smart Limits that gives you the ability to block specific numbers (primarily used for childproofing) but does not keep all text messages from reaching you, and it costs $5 a month as of October 2011.
Jailbreaking for Text Blocking
Jailbreaking your phone is necessary to have access to apps that block texts. In most cases, this involves a simple installation of jailbreaking software (such as Spirit) that modifies the iPhone's core OS. Jailbreaking opens up iPhone functionality, but it could void your Apple warranty, violate other provider terms or damage your phone.
Once your phone is jailbroken, acquire the iBlacklist app directly from the vendor site. This will install the free version of iBlacklist, which enables you to set up limited blacklists. The full version of the software must be purchased and costs around $12 as of October 2011. iBlacklist helps you manage blacklists for calls as well as text messages.
iClarified: Protect Your Secret Life
iClarified is a third-party software source that allows you to add PYSL (Protect Your Secret Life) to your iPhone. Once installed, PYSL allows you to create blacklists and whitelists to filter your text messages. It also enables you to password-protect text message strings so you can view them later in private.