Driving relay directly from optocoupler, what is best?
Are there any downsides to this method?


For most Relay/optoisolator combinations, this won't work because many relays need a current that is larger than the 50mA sinking current provided by most optoisolators. Using the optoisolator to drive another NPN works well without much addtional cost.


Source: https://howtomechatronics.com/tutorials/arduino/control-high-voltage-devices-arduino-relay-tutorial/