How can I fetch real time stock data to excel

I want to fetch stock prices to excel analyse them and then create an app based on analysis. Help me fetch real time data and historical data of stocks for every sec