First of all, delete everything from your game that you can. Secondly, if you have stuff next to each other, DOCK THEM TOGETHER if possible. It resuls in a smaller Persistant.qks file. Also avoid structs, solar panels. Switch off whichever engines you can, including RCS. And if you can, stay more than 5km from any other craft. These things all reduce lag.