School success is important, but it isn't everything. Do your best, but don't consider it the measure of your worth as a person. Do your best, but don't get caught up in comparing yourself to others or trying to be perfect.
Success Tips -- Tactical
Most importantly, you must stop telling yourself that you can't succeed or can't do it!
Second, you need to work harder -- sorry!!! For starters, just work about 15 minutes extra per day per subject in middle and high school. Work 30 minutes extra per day per subject in college. You can move from drudgery to insight by doing this. 98% of your fellow students won't do this -- so your grades will be higher than at least 90% of your fellow students.
(If you don't do anything except the first two "techniques" above, you will see an immediate benefit that may put you back on track.)
Third, handle peer pressure. Peer pressure on boys/men is most often in the negative direction. Sorry to say this, but it's true. So, be prepared for this and decide, in advance, to not be a victim of pressure by "friends" to be and do less than you are capable of in order to be "cool". Find a friend or two who also need to succeed and who have good study habits. Set up accountability sessions and, possibly, study sessions. Be aware of pairing with a high IQ speed learner!!! It will just frustrate you. Find someone slightly above your own knowledge level who also needs to work hard for their grades.
Fourth, listen to your teachers when they are talking -- and actually take notes on what they are saying. In high school, teachers are often giving you the answers to test questions. They are almost always telling you what your assignment needs to contain. Why wouldn't you listen? Peer pressure to seem cool?
Fifth, take notes on things you don't know -- not on everything the teacher says. Do take notes, however, even if it isn't cool. You can take a lot fewer notes if you have already read the material.
Six, stay slightly ahead of the lessons. If you haven't read the material or done the homework before a teacher/college lecture, you will be making your work twice to three times as hard. I can't tell you how many times I hadn't read the lesson and, basically, only got 20% of what I could have from the lessons. The emotional anxiety of constantly being behind in your lessons steals joy from your life. Being ahead makes you seem and become smarter than almost everyone.
Seven, ask for help. Teachers and professors love to "coach" if the student has prepared and tried it on their own first. Ask your smarter or harder-working friends. Don't get your advice from someone who is clueless or doesn't have your best interests in mind. Don't be a slacker and expect to get the full level of help from your coaches, however. Think of it as similar to a basketball player asking their coach for more playing time when they haven't put the work in to stay in shape or develop basic skills.
Success Tips -- Strategic
Motivation of having a career plan: If you find it hard to get yourself going, you may be lacking in purpose. It is hard to do hard work for months and years when you don't have a passion for something that the work is preparing you for. With the simplest of starter jobs, they at least give you a paycheck that will allow you to buy stuff, take your girl out on a date, put gas in your car, etc. Try going to https://youngmenslives.com/careers if you are lacking in motivation.
Take courses that you will learn from -- not just ones that will increase your GPA. Eventually, you will be smarter as a result and the grades will come naturally. When you become a professional, the knowledge gained by doing this will make you much more effective and successful.
Try to really understand the material -- not just get a good grade. See how it can be applied. Test "what if". Play with various cases and limits to see what happens. Ask how it might apply to a situation or problem in the career you are interested in. This is especially important with basics courses that form the foundation for advanced courses in the same subject. It is even more important if you plan a career in an area. I graduated with some high grades in certain subjects because I knew how to take tests and turned in all of my work. I didn't really understand the material, however, and found myself unable to complete project work in the "real world" after graduation!!!
Internships: If you have an opportunity to do so during college, try to become an intern or coop in your career area of choice. You will learn if you even like this work before you dedicate X more years to your education in this area. You will have experience to add to your resume. You will make contacts who can help you with references or, even, offer you a good job once you graduate. Being interested in chemistry and healthcare, one of my friends in high school was able to land a simple job in a pharmacy -- so you don't even have to wait until you are in college.
Major and "Undeclared Major": If you don't have any idea what your career interests are, going to college is very expensive and a lot of hard work. I'm not suggesting that you take a year off to discover yourself, but I am suggesting that you at least read the Careers article on this website before you spend $200K and five years of your life on something you don't care about. If you do take a year off to discover yourself and your parents pay for you to take a massive vacation traveling Europe, just be aware that an endless vacation isn't a reality for most of us. If you are taking a year off from college, you would be better served to get a job in an area you might be interested in. (Take a month in Europe first, of course, if someone else is paying for it.)
Return on Investment: Try to go to an economical undergraduate college unless your parents just have so much money they don't know what to do with it. Exceptions would be going to Harvard, Stanford, Yale or MIT. Make a deal with your parents to pay for grad school instead of paying big bucks for undergrad.
Loans and debt: If you aren't getting college money from your parents, use student loans but live frugally and go to an economical college. If you have to be self-sufficient, make sure you are getting a degree in something that will lead to good employment. You can find careers that are at the intersection of your talents, your interests, and what someone will pay you for -- if you think about it creatively and are willing to consider them "starter" opportunities.
You can be successful in school if you want to, but you are probably going to have to work harder. You don't have to be perfect or the best to be very successful. Let learning and your career success, not perfect grades, be the driver.