It's definitely not a problem with the MacBook. If I had to wager a guess I would suspect a problem with the router or modem.