Hobione's Weblog

Living & Breathing in Web 2.0 Era


Error: java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener

The Spring projects has many modules.

  1. Spring Web MVC (spring-webmvc.jar)
  2. Spring Aop (spring-aop.jar)
  3. Spring Beans (spring-beans.jar)
  4. Spring Context (spring-context.jar)
  5. Spring Core (spring-core.jar)
  6. Spring Dao (spring-dao.jar)
  7. Spring Hibernate (spring-hibernate3.jar)
  8. Spring Ibatis (spring-ibatis.jar)
  9. Spring Jca (spring-jca.jar)
  10. Spring Jdbc (spring-jdbc.jar)
  11. Spring Jdo (spring-jdo.jar)
  12. Spring Jms (spring-jms.jar)
  13. Spring Jms (spring-jpa.jar)
  14. Spring Jmx (spring-jmx.jar)
  15. Spring Portlet (spring-portlet.jar)
  16. Spring Remoting (spring-remoting.jar)
  17. Spring Struts (spring-struts.jar)
  18. Spring Support (spring-support.jar)
  19. Spring Toplink (spring-toplink.jar)
  20. Spring Web (spring-web.jar)
  21. Spring Aspects (spring-aspects.jar)

Solution: My project was missing Spring-web.jar  Two ways to fix this.
1. Add Spring-web.jar to the WEB-INF/lib dir
2. Add a dependency tag to the pom.xml file (preferred).  At this time I am using Spring 2.5.4


April 5, 2009 - Posted by | Spring Framework


  1. Hello, it continuous with same error. I added spring-web.jar in WEF-INF/lib of my proyect, and it didn’t go. And then, I added


    in pom.xml, but it didn’t go. Can you help me? Thank, regards


    Comment by Elena | May 13, 2009 | Reply

    • What is the error? What IDE are you using? Make sure do a clean build. Close IDE and restart, clear cache etc.
      – Hobi

      Comment by HobiOne | May 13, 2009 | Reply

  2. Error configuring application listener of class org.springframework.web.context.ContextLoaderListener

    after adding above dependency..its still throwing above error can u plz help me…what i vl do

    Comment by Navneet | January 27, 2010 | Reply

  3. Plz change ur tomcat

    Comment by vijay | February 15, 2010 | Reply

  4. Hi although I think it would be same answer but I have recently downloaded tomcat 7 and have deployed an spring mvc app over it. I am getting same ‘java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener’ error, I have verified that org.springframework.web-3.1.2.RELEASE.jar is present in the web-app lib folder and the required file is present inside it. Tried to to app clean and redeploying app but still with no luck.
    Please help

    Comment by tarun | October 9, 2012 | Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: