because luffy wants to be king of the pirates and is also fighting a war against the world government
in an arc at about episode 278, luffy goes to save one of his crewmates at a government prison. While doing so, he asks one of his crewmates to shoot a hole into a world government flag, which means a declaration of war. Luffy and his crew are constantly battling the marines and world government to get stronger and to try to find the one piece. The declaration of war, the journey to sabaody, and luffy's brother being imprisoned all lead to luffy having to get stronger so he can enter the new world, which is where the one piece is most likely located. Once he claims the one piece and wins the war against the world government, he can finally become the king of the pirates, the ultimate end goal of the series