Powering Atmega328P-Pu externally
1.8 - 5.5V (max)

The datasheet (http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-42735-8-bit-AVR-Microcontroller-ATmega328-328P_Summary.pdf) will tell you that input Voltage is: 1.8 - 5.5V

That's max of 5.5V so don't use 9V battery without a voltage divider.
To power the chip all you need is voltage to Pin 7 and GND to PIN 8.

16Mhz Crystal Most Likely Required

However, to get it to work after removing the chip from an Arduino Uno board you will also need a 16Mhz Crystal on pins 9 &amp; 10.  You will also need two 22pF capacitors on pins 9 &amp; 10, each connected to ground.

I've written this all up with pictures at my blog: http://raddev.us/arduino/post/2018/07/03/arduino-uno-using-your-atmega328p-u-as-stand-alone

Your final circuit will look something like the following (from my blog article):


Without the Crystal you will most likely find that your sketches don't seem to run.

Note: The red LED is connected just as a blink test (more on that in the article).