The War of 1812 ended when JQA signed a Treaty called the Treaty of Ghent I believe. It stated that everything won by either country during the war was to be returned to the rightful country. The US then became a respected nation because of this. They didn't win against GB, but they didn't loose.