Because I figured it would help, here are the three easiest ways to tell if you need to replace guitar strings.
1: Inability to properly tune a string or strings
What I mean by this is that, if you use a tuner and it won't register what type of note you're playing, then there's definitely a problem. Sometimes it may be the tuners fault, but if the unregistered notes have an unintentional grinding noise to them, I would advise just changing the strings. From personal experience, the only thing you're going to achieve by continuing your attempts at tuning the "grind" string is that you're going to have a broken string.
2: Inability to perform certain guitar techniques
If you know how to do guitar techniques, such as sliding, string bending or power chords and you're now getting a flat sound from all attempts to use these techniques, you should apply more pressure to the strings, but if the problem or problems persist for more than a couple days after you've been applying pressure, then it's probably time to put some new strings on your instrument. Trust me, it will help.
Finally, the fairly obvious one:
If you haven't replaced your strings ever and you bought your instrument over one year ago, you probably need to change your strings. They get worn down with continued use and if you play guitar enough to be on this website, you have most likely worn out any "default" strings that were on your guitar to begin with, so, if you have the money and you're guitar's not acting the way you think it should, go to a music store and get yourself some replacement strings.
IMPORTANT: When you're buying strings for the first time, be sure to have someone at the store show you how to change strings. It'll probably cost a bit more than doing it yourself, but their advice is worth it!