Listen, before I give you a list of tips that'll cure your laziness, it's important to be straightforward and upfront with yourself.
I don't want the rest of my time spent writing this post to be in vain because you can't own your sh*t and take action.
There are a plethora of reasons why you may not be going to class.
Before anything else, I'd recommend you take a walk without your phone or any distractions, and think about why you're going to school in the first place. I mean really think about it.
Clearly, your main problem is a lack of motivation, respect for yourself, and self-discipline.
If that's the case, those are your main issues, not the class.
Talking about it with people close to you or even a therapist might help - but until you learn to respect yourself and put in the work, blog posts written by random guys on the internet aren't going to help you change your behavior.
On the other hand, if you aren't motivated to go to class because you don't know why you're in college, I don't blame you.
I actually dropped out of college because I knew the standard "go to college, get a job, marry and settle down" path wasn't for me.
In class, I often found myself thinking about making money online, via sales and online marketing. It was hard to go to class because I hated the class.
Why was I forced to learn about politics and poetry when I was majoring in computer science, to become a software engineer?
If you find yourself questioning your path, and that's why your motivation is lacking, I'm a huge advocate of taking some time off from school and figuring out what you want to do with your life.
Going to college because "you're supposed to go" isn't a valid reason in my opinion, unless you know what the end result is.
For example, if you know you want to be a nurse, doctor, lawyer, etc., college is mandatory.
On the other hand, if you want to start a business, or have no clue what you want to do, why go 100k in debt for a degree you probably won't use?
I'm going on a bit of a tangent now, so let's get back on track.
The point is, it'll be far easier to motivate yourself if you know why you're doing what you're doing.
Too many college kids go without knowing the end result, drinking their way through school without a plan.
I highly recommend you nail down your purpose BEFORE anything else, so you can hold yourself accountable.
Once your purpose is clear, the rest will fall in line.
Don't try to force yourself to go to class if you, deep down, hate/resent what you're doing. It'll never work, and your old habits/patterns will return.
Conversely, the girl across from my dorm room knew she wanted to be a nurse.
While most around her were out partying, she was studying.
Incredibly serious about school and becoming a nurse, she had no issue sacrificing her social life to wake up early, go to class, study, and get sh*t done.
What's the bottom line here?
Take responsibility for your life, figure out your purpose, and go after it.
The motivation and self-respect - the importance of which cannot be overstated - will come when you know what you're doing is right.