Bureaucratic history time! Yes, this agency (and its predecessors) have always been responsible for GDP; GDP was created a couple decades after the Department of Commerce and the Department of Labor split up.
The full answer is that the Bureau of Economic Analysis (BEA) was created in 1972 as a bureau in the Social and Economic Statistics Administration (SESA), then made an autonomous bureau within the Department of Commerce in 1975, with the abolishment of the SESA.
When the BEA was created in 1972, it was created out of the Office of Business Economics (itself an autonomous unit) in the Department of Commerce. In turn, the Office of Business Economics was established in 1945 inside another autonomous unit, that parent unit being the Bureau of Foreign and Domestic Commerce.
It was during the period of the Bureau of Domestic and Foreign Commerce (housed in the Department of Commerce) that GDP was created (in part by the work of Simon Kuznets on a measure of national income), but the agency preceded this by many years.
The Bureau of Foreign and Domestic Commerce, for its part, was transferred to the the Department of Commerce when the DoC was created in 1913 (by splitting up the Department of Commerce and Labor into two separate cabinet departments). It had previously been within the Department of Commerce and Labor, and was known as the Bureau of Statistics prior to 1912.
The Bureau of Statistics in the Department of Commerce and Labor was created out of the Bureau of Foreign Commerce (housed in the Department of State), and the Bureau of Statistics (housed in the Department of the Treasury). Each of those bureaus also had other names during the 19th century, but we've probably already gone way further back than you had intended.
This history thanks to the National Archives.