It's temperamental if you use the default url. It works if you change the url to 'https':
connect = fred('https://research.stlouisfed.org/fred2/'); d = fetch(connect,'GDPC96');
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!