The two nations agreed to tighter cooperation on coastal security, regular talks between their respective defence and foreign ministers, and greater Japanese investment in Indonesia.
"We wish to contribute to the peace and prosperity of this region and the international community by strengthening our strategic partnership with Indonesia, which, like Japan, is a maritime nation and democracy," Abe told Widodo as they began their talks.
Widodo's visit to Tokyo is a part of his week-long tour of Japan and China, aimed at attracting investment and forging closer political ties.
Widodo has previously told Japanese media that China's claim to virtually all of the South China Sea has no legal foundation.
More From This Section
Indonesia "is ready to play a role of mediator" between Tokyo and Beijing, Widodo told NHK before his trip.
Roughly 1,500 Japanese firms are operating in Indonesia, and Tokyo is Jakarta's top aid donor.
Indonesia, by contrast, counts Japan as the number one destination for its exports, particularly its energy sales.
Ahead of his visit, the Indonesian leader told Japanese media that he was interested in Japan's assistance to build key infrastructure, such as power plants, highways, and railways.