# Is there is any method instead of Thread.sleep()?

**URL:** <https://forum.katalon.com/t/is-there-is-any-method-instead-of-thread-sleep/7512>\
**Category:** Miscellaneous\
**Tags:** katalon-studio\
**Created:** [May 30, 2017, 2:56pm UTC](https://forum.katalon.com/t/is-there-is-any-method-instead-of-thread-sleep/7512 "2017-05-30T14:56:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pranesh](https://avatars.discourse-cdn.com/v4/letter/p/e36b37/32.png) [@pranesh](https://forum.katalon.com/u/pranesh)\
**Post date:** [May 30, 2017, 2:56pm UTC](https://forum.katalon.com/t/is-there-is-any-method-instead-of-thread-sleep/7512/1 "2017-05-30T14:56:02Z")

</div>

When my webpage is faced error on run-timeout error while navigating or clicking element,that time to solve my error i use **Thread.sleep()**.But my Senior Architect says using **Thread.sleep()** method is wrong way try to use **Smart Loading method**.

Is there is any method to use loading the page instead of Thread.sleep() method?

---

<div class="post-metadata">

**Author:** ![Zarashima](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/zarashima/32/928_2.png) [@Zarashima](https://forum.katalon.com/u/Zarashima)\
**Post date:** [May 30, 2017, 3:48pm UTC](https://forum.katalon.com/t/is-there-is-any-method-instead-of-thread-sleep/7512/2 "2017-05-30T15:48:52Z")

</div>

Yes that’s right. Please don’t use that wait in real automation test execution due to it’s just a workaround solution and will fail your test execution any time.

You can use ‘[Wait For Page Load](https://docs.katalon.com/display/KD/%5BWebUI%5D+Wait+For+Page+Load)’ keyword in this case
