Some additional information would be helpful.
- Are you connected to the wifi but can't browse the Internet
- Do you get an IP Address?
- What Operating System are you using?
It's hard to answer this question definitively without the answers to my questions above, but lets do some troubleshooting.
Is your router out of IP addresses. Many consumer based routers only allow a certain number of unique devices to be connected, it's possible that your router is working properly and just denying your computer an IP address.
It's possible that your router and/or modem have gone bad, home routers are such a competitive market that they build them cheaply and are not designed to last forever. Often a new router will fix all the problems of an older one.
If your computer is using an older wifi standard such as 802.11g and your router only has 802.11n turned on it will not be able to connect properly. Make sure the router wireless standard and computer wireless standard match.
On your computer do a dns flush (I'd tell you how if I knew your OS), and reboot the computer. Also try to "forget" and re-connect to your router, often it just needs a second chance to figure everything else.
Answer my questions above and I might be able to offer a more direct answer.