What is PortFast ?
PortFast is a cisco proprietary STP enhancement. It can be used with STP or RSTP. Let’s first discuss STP or Spanning Tree Protocol. Spanning Tree Protocol is used to quickly prevent and eliminate bridging loops. If you enable PortFast on a port that is connected to another Layer 2 device, such as a switch, you might create network loops.
The time Spanning Tree Protocol (STP) takes to transition ports over to the Forwarding state can cause problems such as booting into WDS or getting a/ workstation getting an IP address to login to a domain. PortFast can be used to speed up this time on a port (e.g for workstations)
Turning on PortFast or using the Spanning-tree portfast trunk command should never be used on switch interconnects because with switch interconnects you want STP to make sure there is no loop before forwarding.
A loop is not formed by enabling portfast on trunk ports. If you do have a loop and your switch interconnects have portfast enabled then the switch will not be able to detect the loop in time.
Enabling portfast on a port does not disable STP but it allows the port to forward immediately.