Also keep your resume up-to-date so they know what you keep doing and to keep track of your progress
The main way to keep your job is be the best so that your boss says “there's no way I could ever do my job without him/her”
Also another way is if you hear that layoffs are coming don’t do anything that gives them a good reason to lay you off.
Another way is to be valuable beyond your department In other words don’t be only able to do one certain job be flexible.
Try to find some people who could help you find your newer job that have a little more pull in the work force
And put in some resume’s in other places that could use your skills and so if you get a layoff you can have other choices
And If you try some of these suggestions you shouldn’t have to fear the layoffs and that everything happens for a reason and you can get a better job if you get fired