The paper defines the essence and role of the external sector in the development of the national economy. It has been studied that the main endogenous and exogenous factors affecting the state and structure of the external sector of the national economy are globalization, technological progress, foreign economic policy and economic integration. The impact of the war on the development of the external sector of Ukraine's economy is substantiated. In particular, the main consequences of the impact of the war on the external sector of Ukraine's economy are the disruption of trade, the insecurity of investments, and the instability of the national currency. It was analyzed that during the period 2020-2022, the deficit of foreign trade in goods and services of Ukraine increased significantly, by more than two times. This negative trend was due to a significant reduction in the export of Ukrainian goods caused by military actions, which led to a decrease in production and complications with logistics. On the other hand, the import of goods to Ukraine decreased slightly. An important aspect is that the share of raw materials in the export structure is constantly growing. Only in the period of 2021-2022, the share of raw products in the export structure increased by as much as 13.3%, which is of a threatening nature in general for the national security of Ukraine. The structure of imports almost did not change, but the volume of imports also decreased, although significantly less than exports. Such a reduction in imports, especially in 2022, is dictated by the contraction of Ukraine's economy, primarily the level of consumption. Since at least 3 million people left Ukraine during the war, inflation and devaluation of the national currency increased, and the economy was partially transferred to military lines. It has been established that a chronic deficit in the balance of goods and services can lead to the accumulation of external imbalances and negatively affect the stability of the country's economy. The analysis of the external debt structure of the Ukrainian economy reveals both challenges and opportunities. While the high level of external debt poses risks to economic stability, it also highlights the need for prudent fiscal management, structural reforms and investment in key sectors. By solving these challenges and using its strengths, Ukraine will be able to manage the dynamics of external debt and build a sustainable and growing economy.