# How to pass argument in keyword Robot framework same Cucumber

**URL:** <https://forum.robotframework.org/t/how-to-pass-argument-in-keyword-robot-framework-same-cucumber/8775>\
**Category:** Robot Framework\
**Created:** [14 April 2025 03:22 UTC](https://forum.robotframework.org/t/how-to-pass-argument-in-keyword-robot-framework-same-cucumber/8775 "2025-04-14T03:22:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![alice88](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/alice88/32/4724_2.png) [@alice88](https://forum.robotframework.org/u/alice88)\
**Post date:** [14 April 2025 03:22 UTC](https://forum.robotframework.org/t/how-to-pass-argument-in-keyword-robot-framework-same-cucumber/8775/1 "2025-04-14T03:22:18Z")

</div>

Hi everyone,  
In Cucumber, i have step below:  
When I input “[abc@gmail.com](mailto:abc@gmail.com)” to username and “12345” to password  
So i want to convert it to robotframework below : I input ${username} to username and ${password} to password.  
But it seems that params can only be placed at the end of the keyword.  
is there any way to set param as i want??

---

<div class="post-metadata">

**Author:** ![laurentbristiel](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/laurentbristiel/32/4594_2.png) [@laurentbristiel](https://forum.robotframework.org/u/laurentbristiel)\
**Post date:** [14 April 2025 06:07 UTC](https://forum.robotframework.org/t/how-to-pass-argument-in-keyword-robot-framework-same-cucumber/8775/2 "2025-04-14T06:07:49Z")

</div>

Hello,

It is actually possible to embed arguments within keywords to achieve something similar to your Cucumber test, see this section of the user guide:

[https://robotframework.org/robotframework/latest/RobotFrameworkUserGuide.html#embedded-arguments-matching-wrong-values](https://robotframework.org/robotframework/latest/RobotFrameworkUserGuide.html#embedded-arguments-matching-wrong-values)

Laurent

---

<div class="post-metadata">

**Author:** ![alice88](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/alice88/32/4724_2.png) [@alice88](https://forum.robotframework.org/u/alice88)\
**Post date:** [14 April 2025 06:54 UTC](https://forum.robotframework.org/t/how-to-pass-argument-in-keyword-robot-framework-same-cucumber/8775/3 "2025-04-14T06:54:40Z")

</div>

thanks so much,Laurent 😄
