[SOLVED] Footprint for EL817S1 (SMD version of EL817 / PC817 opto coupler)

Well, that would have been a lot easer for me if you had provided a datasheet. Here is the one that I found:

It looks like all the SMT variants are just a re-forming of the leads on the same 4-pin DIP package. Page 9 of the datasheet gives the manufacturer suggested dimensions for the pad layout for a footprint, and often that is all the designer gets for a footprint (partly because there are so many different EDA packages out there all with incompatible library file formats). What I would do is take the 4-pin DIP package from what ever library I’ve decided is standard for me to modify to a new footprint for this part. Just change the pads from THT to SMT, re-size and position according to the datasheet. Then just double-check the other layers and modify them if needed.

Refer to the link that @jmk provided (and the links in that FAQ item) for a better understanding of footprint (and general library) organization, maintenance, and creating new assets (either from scratch or as I suggested above based on an existing asset). I’d like to highlight one point that a lot of newbies don’t get right away: The libraries that come with KiCad are read only. This is because they will get changed when you upgrade KiCad and if you had saved your own edits there you will loose your edits. You will need to set up your own personal libraries to collect all your new footprints and symbols. This FAQ (which is linked in the FAQ that @jmk provided) gives good and sensible organization ideas for your own libraries.